Skip to content
This repository has been archived by the owner on Jan 14, 2022. It is now read-only.

Commit

Permalink
Fixed issue in log.write() message when message parameter is omitted
Browse files Browse the repository at this point in the history
  • Loading branch information
f2bo committed Feb 3, 2016
1 parent 45ee7dd commit a8598ab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/log.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ if (!log) {
var color = colorMap[severity] || colorMap['default'];
cursor[color]();

message = message.replace(/\n/g, '\n' + new Array(maxLenSeverity + maxLenSource + 6).join(' '));
message = (message || '').replace(/\n/g, '\n' + new Array(maxLenSeverity + maxLenSource + 6).join(' '));

if (methodName !== 'write') {
source = source || loggerName || getApplicationName();
Expand Down

0 comments on commit a8598ab

Please sign in to comment.