From eda7aac5ef343fa6280b69f7f323d420d84f756c Mon Sep 17 00:00:00 2001 From: Ajay Date: Tue, 24 May 2022 23:31:43 -0400 Subject: [PATCH] Add time to log messages --- src/utils/logger.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/logger.ts b/src/utils/logger.ts index ed419e99..2d3a1b92 100644 --- a/src/utils/logger.ts +++ b/src/utils/logger.ts @@ -4,9 +4,9 @@ window["SBLogs"] = { }; export function logDebug(message: string) { - window["SBLogs"].debug.push(message); + window["SBLogs"].debug.push(`[${new Date().toISOString()}] ${message}`); } export function logWarn(message: string) { - window["SBLogs"].warn.push(message); + window["SBLogs"].warn.push(`[${new Date().toISOString()}] ${message}`); } \ No newline at end of file