From 0b89460c18eecc0ee39ae562ab6bb44616ea59c5 Mon Sep 17 00:00:00 2001 From: Andrew Casey Date: Wed, 16 May 2018 13:36:02 -0700 Subject: [PATCH] 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. --- src/server/editorServices.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/editorServices.ts b/src/server/editorServices.ts index 459b4b12d8314..bb3560cbde521 100644 --- a/src/server/editorServices.ts +++ b/src/server/editorServices.ts @@ -2123,7 +2123,7 @@ namespace ts.server { } private telemetryOnOpenFile(scriptInfo: ScriptInfo): void { - if (!this.eventHandler || !scriptInfo.isJavaScript() || !addToSeen(this.allJsFilesForOpenFileTelemetry, scriptInfo.path)) { + if (this.syntaxOnly || !this.eventHandler || !scriptInfo.isJavaScript() || !addToSeen(this.allJsFilesForOpenFileTelemetry, scriptInfo.path)) { return; }