workspace.rootPath should be undefined when no folder is open, not null. fixes #690

This commit is contained in:
Johannes Rieken
2015-11-26 15:38:29 +01:00
parent c65770e8a0
commit 3e1cbe1209

View File

@@ -189,7 +189,7 @@ export class PluginHostAPIImplementation {
};
//
const workspacePath = contextService.getWorkspace() && contextService.getWorkspace().resource.fsPath;
const workspacePath = contextService.getWorkspace() ? contextService.getWorkspace().resource.fsPath : undefined;
const pluginHostFileSystemEvent = threadService.getRemotable(PluginHostFileSystemEventService);
const pluginHostWorkspace = new PluginHostWorkspace(this._threadService, workspacePath);
const pluginHostDocuments = this._threadService.getRemotable(PluginHostModelService);