From 32406c3f6ab87781ab5cbea2730626731a6959dc Mon Sep 17 00:00:00 2001 From: Ladislau Szomoru <3372902+lszomoru@users.noreply.github.com> Date: Tue, 16 Mar 2021 16:22:43 +0100 Subject: [PATCH] Recalculate trust when workspace folders change --- src/vs/workbench/services/workspaces/common/workspaceTrust.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/services/workspaces/common/workspaceTrust.ts b/src/vs/workbench/services/workspaces/common/workspaceTrust.ts index e8005a80565..607d6c29305 100644 --- a/src/vs/workbench/services/workspaces/common/workspaceTrust.ts +++ b/src/vs/workbench/services/workspaces/common/workspaceTrust.ts @@ -253,6 +253,7 @@ export class WorkspaceTrustService extends Disposable implements IWorkspaceTrust this.logInitialWorkspaceTrustInfo(); + this._register(this.workspaceService.onDidChangeWorkspaceFolders(() => this.currentTrustState = this.calculateWorkspaceTrustState())); this._register(this.dataModel.onDidChangeTrustState(() => this.currentTrustState = this.calculateWorkspaceTrustState())); this._register(this.requestModel.onDidCompleteRequest((trustState) => this.onTrustRequestCompleted(trustState))); this._register(this.requestModel.onDidCancelRequest(() => this.onTrustRequestCancelled()));