mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-22 01:29:04 +01:00
Marking that documents/workspaces arrays cannot be mutated
This commit is contained in:
@@ -634,7 +634,7 @@ export default class TypeScriptServiceClient extends Disposable implements IType
|
||||
}
|
||||
|
||||
public getWorkspaceRootForResource(resource: vscode.Uri): string | undefined {
|
||||
const roots = vscode.workspace.workspaceFolders;
|
||||
const roots = vscode.workspace.workspaceFolders ? Array.from(vscode.workspace.workspaceFolders) : undefined;
|
||||
if (!roots || !roots.length) {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user