From 30367a133882acf5d92e2265a6a95e824f588c7f Mon Sep 17 00:00:00 2001 From: Dorian Niemiec Date: Sun, 17 Mar 2024 21:39:21 +0100 Subject: [PATCH] Fix the "SERVER MESSAGE" in SVR.JS log viewer and log highlighter --- loghighlight.js | 2 +- logviewer.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/loghighlight.js b/loghighlight.js index 4c7737d..b4a97f3 100644 --- a/loghighlight.js +++ b/loghighlight.js @@ -45,7 +45,7 @@ function viewLog(log) { } else if(log[i].indexOf("SERVER WARNING MESSAGE") != -1) { log[i] = log[i].replace("SERVER WARNING MESSAGE","\x1b[43m\x1b[1mSERVER WARNING MESSAGE\x1b[22m") + "\x1b[40m\x1b[0m"; } else if(log[i].indexOf("SERVER MESSAGE") != -1) { - log[i] = log[i].replace("SERVER MESSAGE","\x1b[43m\x1b[1mSERVER WARNING MESSAGE\x1b[22m"); + log[i] = log[i].replace("SERVER MESSAGE","\x1b[1mSERVER MESSAGE\x1b[22m"); } console.log(log[i]); } diff --git a/logviewer.js b/logviewer.js index 2a2376d..b2d62b9 100644 --- a/logviewer.js +++ b/logviewer.js @@ -76,7 +76,7 @@ function viewLog(log) { } else if(log[i].indexOf("SERVER WARNING MESSAGE") != -1) { log[i] = log[i].replace("SERVER WARNING MESSAGE","\x1b[43m\x1b[1mSERVER WARNING MESSAGE\x1b[22m") + "\x1b[40m\x1b[0m"; } else if(log[i].indexOf("SERVER MESSAGE") != -1) { - log[i] = log[i].replace("SERVER MESSAGE","\x1b[43m\x1b[1mSERVER WARNING MESSAGE\x1b[22m"); + log[i] = log[i].replace("SERVER MESSAGE","\x1b[1mSERVER MESSAGE\x1b[22m"); } console.log(log[i]); }