提交 f063ff93 编写于 作者: S Sandeep Somavarapu

Fix #103238

上级 1fb3a59b
......@@ -431,6 +431,9 @@ export class UserDataSyncWorkbenchContribution extends Disposable implements IWo
private async turnOn(): Promise<void> {
try {
if (!this.userDataSyncWorkbenchService.authenticationProviders.length) {
throw new Error(localize('no authentication providers', "No authentication providers available."));
}
if (!this.storageService.getBoolean('sync.donotAskPreviewConfirmation', StorageScope.GLOBAL, false)) {
if (!await this.askForConfirmation()) {
return;
......@@ -478,7 +481,7 @@ export class UserDataSyncWorkbenchContribution extends Disposable implements IWo
return;
}
}
this.notificationService.error(localize('turn on failed', "Error while starting Sync: {0}", toErrorMessage(e)));
this.notificationService.error(localize('turn on failed', "Error while starting Settings Sync: {0}", toErrorMessage(e)));
}
}
......
......@@ -246,6 +246,9 @@ export class UserDataSyncWorkbenchService extends Disposable implements IUserDat
}
async turnOn(): Promise<void> {
if (!this.authenticationProviders.length) {
throw new Error(localize('no authentication providers', "Settings sync cannot be turned on because there are no authentication providers available."));
}
if (this.userDataAutoSyncService.isEnabled()) {
return;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册