1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Fix node.error() not printing when passed false (#1037)

This should fix #1036
This commit is contained in:
Ben Hardill 2016-11-07 18:28:35 +00:00 committed by Nick O'Leary
parent 9a4ff5cb43
commit 0a5a42b32a

View File

@ -236,7 +236,9 @@ Node.prototype.warn = function(msg) {
};
Node.prototype.error = function(logMessage,msg) {
logMessage = logMessage || "";
if (typeof logMessage != 'boolean') {
logMessage = logMessage || "";
}
log_helper(this, Log.ERROR, logMessage);
/* istanbul ignore else */
if (msg) {