From d9643993b5cf6486ca669cb55d0eae5c359ba449 Mon Sep 17 00:00:00 2001 From: tom-shan Date: Mon, 23 Mar 2020 09:10:27 +0800 Subject: [PATCH] fix #7393 can't open tomcat configuration without workspaces opened When no workspaces are opened, storagePath should return undefined in accordance with the vscode implementation(https://github.com/microsoft/vscode/blob/416bb2e8d08f123df4bfb458070fcbb9fb69a3da/src/vs/workbench/api/node/extHostStoragePaths.ts#L46-L49). --- packages/plugin-ext/src/plugin/plugin-manager.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/plugin-ext/src/plugin/plugin-manager.ts b/packages/plugin-ext/src/plugin/plugin-manager.ts index 2916b0d9d6dcc..0a33047a13887 100644 --- a/packages/plugin-ext/src/plugin/plugin-manager.ts +++ b/packages/plugin-ext/src/plugin/plugin-manager.ts @@ -314,7 +314,7 @@ export class PluginManagerExtImpl implements PluginManagerExt, PluginManager { const subscriptions: theia.Disposable[] = []; const asAbsolutePath = (relativePath: string): string => join(plugin.pluginFolder, relativePath); const logPath = join(configStorage.hostLogPath, plugin.model.id); // todo check format - const storagePath = join(configStorage.hostStoragePath || '', plugin.model.id); + const storagePath = configStorage.hostStoragePath ? join(configStorage.hostStoragePath, plugin.model.id) : undefined; const globalStoragePath = join(configStorage.hostGlobalStoragePath, plugin.model.id); const pluginContext: theia.PluginContext = { extensionPath: plugin.pluginFolder,