From 03ff5d8ae1467324be7a3aab517184c2b4ef74d9 Mon Sep 17 00:00:00 2001 From: mikiher Date: Wed, 11 Sep 2024 22:05:38 +0300 Subject: [PATCH] Disregard socketListener.level if level >= FATAL --- server/Logger.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/Logger.js b/server/Logger.js index b10c45b7..5d1a7fa5 100644 --- a/server/Logger.js +++ b/server/Logger.js @@ -86,7 +86,7 @@ class Logger { // Emit log to sockets that are listening to log events this.socketListeners.forEach((socketListener) => { - if (socketListener.level <= level) { + if (level >= LogLevel.FATAL || level >= socketListener.level) { socketListener.socket.emit('log', logObj) } })