mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2024-11-10 01:02:30 +01:00
add eslint rule for no-console
This commit is contained in:
parent
ec16828497
commit
815df94db4
2 changed files with 2 additions and 0 deletions
|
@ -27,5 +27,6 @@ module.exports = {
|
||||||
"indent": ["warn", 4, { "SwitchCase": 1 }],
|
"indent": ["warn", 4, { "SwitchCase": 1 }],
|
||||||
"object-curly-spacing": ["warn", "always"],
|
"object-curly-spacing": ["warn", "always"],
|
||||||
"require-await": "warn",
|
"require-await": "warn",
|
||||||
|
"no-console": "error"
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
|
@ -79,6 +79,7 @@ class Logger {
|
||||||
if (levelStr.length === 4) {
|
if (levelStr.length === 4) {
|
||||||
levelStr += " "; // ensure logs are aligned
|
levelStr += " "; // ensure logs are aligned
|
||||||
}
|
}
|
||||||
|
// eslint-disable-next-line no-console
|
||||||
console.log(colors.Dim, `${levelStr} ${new Date().toISOString()}: `, color, str, colors.Reset);
|
console.log(colors.Dim, `${levelStr} ${new Date().toISOString()}: `, color, str, colors.Reset);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue