openvidu-browser: Node.js platform: ConsoleLogger constructor

Doesn't look right that the argument is ignored and instead global
state is modified. The code later passes in `window.console` anyway,
so this doesn't really change the behavior.

However this change is important for Node.js compatibility, where
`window` is not defined.
pull/672/merge
Juan Navarro 2022-07-27 16:42:24 +02:00
parent b5d7371eed
commit 71b0e6ca43
1 changed files with 6 additions and 6 deletions

View File

@ -33,10 +33,10 @@ export class ConsoleLogger {
constructor(console: Console) {
this.logger = console;
this.log = window.console.log,
this.info = window.console.info,
this.debug = window.console.debug,
this.warn = window.console.warn,
this.error = window.console.error
this.log = console.log,
this.info = console.info,
this.debug = console.debug,
this.warn = console.warn,
this.error = console.error
}
}