Skip to content

Commit 1793652

Browse files
committed
Correct project root path passed to Typings Installer
`createInstallTypingsRequest` has its own logic for extracting the project root path from the project name and it disagrees with the versions in the project flavors. In particular, it only drops the last component of the name if it exists. For folder projects and JS-only contexts, this will not be the case, but the last entry should still be dropped. TL;DR: stop creating filewatchers for "c:/foo/foo.csproj*jscontent/node_modules"
1 parent cc7b46b commit 1793652

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/server/utilities.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ namespace ts.server {
4343
return <Path>"";
4444
case ProjectKind.External:
4545
const projectName = normalizeSlashes(project.getProjectName());
46-
return project.projectService.host.fileExists(projectName) ? <Path>getDirectoryPath(projectName) : <Path>projectName;
46+
return <Path>getDirectoryPath(projectName);
4747
}
4848
}
4949

0 commit comments

Comments
 (0)