src/goLogging: fix the default logger
The default logger should output to console.
Change-Id: I292102799fc1ba5989d3df577db4cd59db03e15a
Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/319889
Trust: Hyang-Ah Hana Kim <hyangah@gmail.com>
Run-TryBot: Hyang-Ah Hana Kim <hyangah@gmail.com>
TryBot-Result: kokoro <noreply+kokoro@google.com>
Reviewed-by: Suzy Mueller <suzmue@golang.org>
diff --git a/src/goDebugFactory.ts b/src/goDebugFactory.ts
index d8e1ed5..4bce258 100644
--- a/src/goDebugFactory.ts
+++ b/src/goDebugFactory.ts
@@ -66,6 +66,8 @@
logger.info(`debug adapter exited: (code: ${code}, signal: ${signal})\n`)
};
}
+
+ dispose() {}
}
const TWO_CRLF = '\r\n\r\n';
diff --git a/src/goLogging.ts b/src/goLogging.ts
index fb1bc9e..9e6af42 100644
--- a/src/goLogging.ts
+++ b/src/goLogging.ts
@@ -93,7 +93,7 @@
let defaultLogger: Logger;
export function setLogConfig(cfg: LogConfig) {
- defaultLogger = new Logger(cfg.level);
+ defaultLogger = new Logger(cfg.level, undefined, true);
}
export function logError(msg: string) {