From f6be4b3cf3e7032559d0873f520322ceee707f1e Mon Sep 17 00:00:00 2001 From: Jake Bailey <5341706+jakebailey@users.noreply.github.com> Date: Fri, 13 May 2022 13:43:14 -0700 Subject: [PATCH] UNDO WEBWORKER CHANGE --- src/tsserver/webServer.ts | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/tsserver/webServer.ts b/src/tsserver/webServer.ts index 704fd3d2887b4..18d9ab4d13e97 100644 --- a/src/tsserver/webServer.ts +++ b/src/tsserver/webServer.ts @@ -1,8 +1,12 @@ /*@internal*/ - -/// - namespace ts.server { + declare const addEventListener: any; + declare const postMessage: any; + declare const close: any; + declare const location: any; + declare const XMLHttpRequest: any; + declare const self: any; + const nullLogger: Logger = { close: noop, hasLevel: returnFalse, @@ -82,7 +86,7 @@ namespace ts.server { } function hrtime(previous?: [number, number]) { - const now = self.performance.now() * 1e-3; + const now = self.performance.now(performance) * 1e-3; let seconds = Math.floor(now); let nanoseconds = Math.floor((now % 1) * 1e9); if (previous) { @@ -105,7 +109,7 @@ namespace ts.server { exit() { this.logger.info("Exiting..."); this.projectService.closeLog(); - close(); + close(0); } listen() {