From db358b5b02231ca794bdadd1bd1c45942664e514 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 17 Sep 2019 15:31:44 -0700 Subject: [PATCH] Fixing a mismatch in default config for webviews --- .../services/environment/browser/environmentService.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/services/environment/browser/environmentService.ts b/src/vs/workbench/services/environment/browser/environmentService.ts index a68e9cef9558a..346c6c6c81b8b 100644 --- a/src/vs/workbench/services/environment/browser/environmentService.ts +++ b/src/vs/workbench/services/environment/browser/environmentService.ts @@ -181,16 +181,17 @@ export class BrowserWorkbenchEnvironmentService implements IWorkbenchEnvironment get webviewExternalEndpoint(): string { // TODO: get fallback from product.json - return this.options.webviewEndpoint || 'https://{{uuid}}.vscode-webview-test.com'; + return (this.options.webviewEndpoint || 'https://{{uuid}}.vscode-webview-test.com/{{commit}}') + .replace('{{commit}}', product.commit || '211fa02efe8c041fd7baa8ec3dce199d5185aa44'); } get webviewResourceRoot(): string { - return `${this.webviewExternalEndpoint}/{{commit}}/vscode-resource{{resource}}` - .replace('{{commit}}', product.commit || '211fa02efe8c041fd7baa8ec3dce199d5185aa44'); + return `${this.webviewExternalEndpoint}/vscode-resource{{resource}}`; } get webviewCspSource(): string { - return this.options.webviewEndpoint || `https://*.vscode-webview-test.com`; + return this.webviewExternalEndpoint + .replace('{{uuid}}', '*'); } }