only register workspace trust request handler

when trust is enabled
This commit is contained in:
SteVen Batten 2021-04-16 07:44:59 -07:00
parent 3e8b31b394
commit d66d392917

View file

@ -64,9 +64,10 @@ export class WorkspaceTrustRequestHandler extends Disposable implements IWorkben
) {
super();
this.registerListeners();
this.showIntroductionModal();
if (isWorkspaceTrustEnabled(configurationService)) {
this.registerListeners();
this.showIntroductionModal();
}
}
private toggleRequestBadge(visible: boolean): void {
@ -82,7 +83,7 @@ export class WorkspaceTrustRequestHandler extends Disposable implements IWorkben
private showIntroductionModal(): void {
const workspaceTrustIntroDialogDoNotShowAgainKey = 'workspace.trust.introduction.doNotShowAgain';
const doNotShowAgain = this.storageService.getBoolean(workspaceTrustIntroDialogDoNotShowAgainKey, StorageScope.GLOBAL, true);
const doNotShowAgain = this.storageService.getBoolean(workspaceTrustIntroDialogDoNotShowAgainKey, StorageScope.GLOBAL, false);
if (!doNotShowAgain && this.shouldShowIntroduction) {
// Show welcome dialog
(async () => {