1
0
mirror of https://git.hibas.dev/OpenServer/NodeLogging.git synced 2025-07-01 12:41:11 +00:00

Fixing not complete color code removal

This commit is contained in:
hibas123
2018-04-09 20:02:34 +02:00
parent e4ea3f660c
commit df39c423fe
6 changed files with 8 additions and 4 deletions

View File

@ -122,7 +122,7 @@ export class Logging {
let index = m.indexOf("\x1b");
while (index >= 0) {
m = m.substring(0, index) + m.substring(index + 4, m.length);
m = m.substring(0, index) + m.substring(index + 5, m.length);
index = m.indexOf("\x1b");
}

View File

@ -6,6 +6,9 @@ Logging.log("i", "am", { a: "an" }, 1000);
Logging.error(new Error("fehler 001"));
Logging.debug("Some Debug infos");
Logging.errorMessage("i", "am", "an", "error");
Logging.log("\x1b[31m\x1b[31m\x1b[31m\x1b[31m\x1b[31m\x1b[31m TEST \x1b[31m\x1b[31m\x1b[31m")
Logging.stdout = false;
for (let i = 0; i < 7000; i++) {
Logging.log(randomBytes(50000).toString("hex"))