mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-08 04:27:09 +03:00
add eslint rule for no-console
This commit is contained in:
@@ -27,5 +27,6 @@ module.exports = {
|
||||
"indent": ["warn", 4, { "SwitchCase": 1 }],
|
||||
"object-curly-spacing": ["warn", "always"],
|
||||
"require-await": "warn",
|
||||
"no-console": "error"
|
||||
},
|
||||
};
|
||||
|
||||
@@ -79,6 +79,7 @@ class Logger {
|
||||
if (levelStr.length === 4) {
|
||||
levelStr += " "; // ensure logs are aligned
|
||||
}
|
||||
// eslint-disable-next-line no-console
|
||||
console.log(colors.Dim, `${levelStr} ${new Date().toISOString()}: `, color, str, colors.Reset);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user