Skip to content
Snippets Groups Projects
Commit 975d05ac authored by rswindell's avatar rswindell
Browse files

Raise the log-level severity (from DEBUG to NOTICE) when sending any M_ERR

messages. There's a lot of places in this script where we just send a
(somewhat explanatory) M_ERR string, but don't log anything locally unless
debug-level logging is enabled, now we'll at least log those messages with
a bit higher severity.
parent 4a49c9ef
No related branches found
No related tags found
No related merge requests found
......@@ -907,12 +907,12 @@ BinkP.prototype.sendCmd = function(cmd, data)
return false;
if (data === undefined)
data = '';
if (this.debug) {
if (this.debug || cmd == this.command.M_ERR) {
if (cmd < this.command_name.length)
type = this.command_name[cmd];
else
type = 'Unknown Command '+cmd;
log(LOG_DEBUG, "Sent "+type+" command args: "+data);
log(cmd == this.command.M_ERR ? LOG_NOTICE : LOG_DEBUG, "Sent "+type+" command args: "+data);
}
var len = data.length+1;
len |= 0x8000;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment