From 1a26463bcb8b900c27d10a4030f2acfb281888a9 Mon Sep 17 00:00:00 2001 From: Colen Garoutte-Carson <49173979+Colengms@users.noreply.github.com> Date: Wed, 17 Feb 2021 14:33:24 -0800 Subject: [PATCH] Move initialization of TimeTelemetryCollector (#6984) --- Extension/src/LanguageServer/clientCollection.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Extension/src/LanguageServer/clientCollection.ts b/Extension/src/LanguageServer/clientCollection.ts index aa15f9edea..9675f83d26 100644 --- a/Extension/src/LanguageServer/clientCollection.ts +++ b/Extension/src/LanguageServer/clientCollection.ts @@ -23,7 +23,7 @@ export class ClientCollection { private defaultClient: cpptools.Client; private activeClient: cpptools.Client; private activeDocument?: vscode.TextDocument; - public timeTelemetryCollector: TimeTelemetryCollector; + public timeTelemetryCollector: TimeTelemetryCollector = new TimeTelemetryCollector(); public get ActiveClient(): cpptools.Client { return this.activeClient; } public get Names(): ClientKey[] { @@ -62,8 +62,6 @@ export class ClientCollection { this.disposables.push(vscode.workspace.onDidChangeWorkspaceFolders(e => this.onDidChangeWorkspaceFolders(e))); this.disposables.push(vscode.workspace.onDidCloseTextDocument(d => this.onDidCloseTextDocument(d))); - - this.timeTelemetryCollector = new TimeTelemetryCollector(); } public activeDocumentChanged(document: vscode.TextDocument): void {