Skip to content

Commit 0b89460

Browse files
committed
Don't collect open-file telemetry on the syntax server
It's throwing an exception (since there's no program from which to retrieve the SourceFile) and there's no reason to fix it since the same files are open in the semantic server.
1 parent aab8d65 commit 0b89460

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/server/editorServices.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2123,7 +2123,7 @@ namespace ts.server {
21232123
}
21242124

21252125
private telemetryOnOpenFile(scriptInfo: ScriptInfo): void {
2126-
if (!this.eventHandler || !scriptInfo.isJavaScript() || !addToSeen(this.allJsFilesForOpenFileTelemetry, scriptInfo.path)) {
2126+
if (this.syntaxOnly || !this.eventHandler || !scriptInfo.isJavaScript() || !addToSeen(this.allJsFilesForOpenFileTelemetry, scriptInfo.path)) {
21272127
return;
21282128
}
21292129

0 commit comments

Comments
 (0)