提交 88449158 编写于 作者: E Erich Gamma

ensure that the scheme is 'file' detecting scripts

上级 c6686be2
......@@ -104,9 +104,13 @@ function isEnabled(folder: vscode.WorkspaceFolder): boolean {
}
async function provideNpmScriptsForFolder(folder: vscode.WorkspaceFolder): Promise<vscode.Task[]> {
let rootPath = folder.uri.fsPath;
let emptyTasks: vscode.Task[] = [];
if (folder.uri.scheme !== 'file') {
return emptyTasks;
}
let rootPath = folder.uri.fsPath;
let packageJson = path.join(rootPath, 'package.json');
if (!await exists(packageJson)) {
return emptyTasks;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册