From 8da1cc8eb27d9d3169b225d40f9d52289b307be0 Mon Sep 17 00:00:00 2001 From: Rob Walch Date: Wed, 25 Oct 2023 07:08:26 -0700 Subject: [PATCH] Remove use of `self` from `enableLogger` Fixes #5905 --- src/utils/logger.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils/logger.ts b/src/utils/logger.ts index 745d4ef584e..eb34cd59380 100644 --- a/src/utils/logger.ts +++ b/src/utils/logger.ts @@ -55,7 +55,7 @@ function exportLoggerFunctions( export function enableLogs(debugConfig: boolean | ILogger, id: string): void { // check that console is available if ( - (self.console && debugConfig === true) || + (typeof console === 'object' && debugConfig === true) || typeof debugConfig === 'object' ) { exportLoggerFunctions(