mirror of
https://github.com/mempool/mempool.git
synced 2025-01-17 18:52:34 +01:00
Syslog priority comparison fix.
This commit is contained in:
parent
cd1273981d
commit
d1b53f4c3a
@ -93,7 +93,7 @@ class Logger {
|
|||||||
prionum = Logger.priorities[priority] || Logger.priorities.info;
|
prionum = Logger.priorities[priority] || Logger.priorities.info;
|
||||||
consolemsg = `${this.ts()} [${process.pid}] ${priority.toUpperCase()}:${network} ${msg}`;
|
consolemsg = `${this.ts()} [${process.pid}] ${priority.toUpperCase()}:${network} ${msg}`;
|
||||||
|
|
||||||
if (config.SYSLOG.ENABLED && Logger.priorities[priority] >= Logger.priorities[config.SYSLOG.MIN_PRIORITY]) {
|
if (config.SYSLOG.ENABLED && Logger.priorities[priority] <= Logger.priorities[config.SYSLOG.MIN_PRIORITY]) {
|
||||||
syslogmsg = `<${(Logger.facilities[config.SYSLOG.FACILITY] * 8 + prionum)}> ${this.name}[${process.pid}]: ${priority.toUpperCase()}${network} ${msg}`;
|
syslogmsg = `<${(Logger.facilities[config.SYSLOG.FACILITY] * 8 + prionum)}> ${this.name}[${process.pid}]: ${priority.toUpperCase()}${network} ${msg}`;
|
||||||
this.syslog(syslogmsg);
|
this.syslog(syslogmsg);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user