mirror of
https://github.com/log4js-node/log4js-node.git
synced 2025-12-08 19:26:01 +00:00
chore(coverage): removed unused check
This commit is contained in:
parent
e3913ce5d7
commit
7234e3ada3
@ -39,13 +39,10 @@ class Logger {
|
||||
categories.setLevelForCategory(this.category, levels.getLevel(level, this.level));
|
||||
}
|
||||
|
||||
log() {
|
||||
/* eslint prefer-rest-params:0 */
|
||||
// todo: once node v4 support dropped, use rest parameter instead
|
||||
const args = Array.from(arguments);
|
||||
const logLevel = levels.getLevel(args[0], levels.INFO);
|
||||
log(level, ...args) {
|
||||
const logLevel = levels.getLevel(level, levels.INFO);
|
||||
if (this.isLevelEnabled(logLevel)) {
|
||||
this._log(logLevel, args.slice(1));
|
||||
this._log(logLevel, args);
|
||||
}
|
||||
}
|
||||
|
||||
@ -83,13 +80,8 @@ function addLevelMethods(target) {
|
||||
return this.isLevelEnabled(level);
|
||||
};
|
||||
|
||||
Logger.prototype[levelMethod] = function () {
|
||||
/* eslint prefer-rest-params:0 */
|
||||
// todo: once node v4 support dropped, use rest parameter instead
|
||||
const args = Array.from(arguments);
|
||||
if (this.isLevelEnabled(level)) {
|
||||
this._log(level, args);
|
||||
}
|
||||
Logger.prototype[levelMethod] = function (...args) {
|
||||
this.log(level, ...args);
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user