Skip to content

Commit

Permalink
Updated default option handling for CLI
Browse files Browse the repository at this point in the history
The defaults were overriding settings specified for colorize and timestamp.  I added a check to see if it's been set, otherwise, default.
  • Loading branch information
oojacoboo committed Nov 9, 2014
1 parent 4134288 commit 39e0258
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/winston/logger.js
Original file line number Diff line number Diff line change
Expand Up @@ -583,8 +583,8 @@ Logger.prototype.cli = function () {
config.addColors(config.cli.colors);

if (this.transports.console) {
this.transports.console.colorize = true;
this.transports.console.timestamp = false;
this.transports.console.colorize = this.transports.console.colorize || true;
this.transports.console.timestamp = this.transports.console.timestamp || false;
}

return this;
Expand Down

0 comments on commit 39e0258

Please sign in to comment.