Skip to content

Commit

Permalink
Fix to change default value to string
Browse files Browse the repository at this point in the history
fixes: #855
  • Loading branch information
abetomo authored and roman-vanesyan committed Sep 15, 2018
1 parent 54b7f14 commit 4c294c1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -1053,7 +1053,7 @@ Command.prototype.optionHelp = function() {
// Append the help information
return this.options.map(function(option) {
return pad(option.flags, width) + ' ' + option.description +
((option.bool && option.defaultValue !== undefined) ? ' (default: ' + option.defaultValue + ')' : '');
((option.bool && option.defaultValue !== undefined) ? ' (default: ' + JSON.stringify(option.defaultValue) + ')' : '');
}).concat([pad('-h, --help', width) + ' ' + 'output usage information'])
.join('\n');
};
Expand Down

0 comments on commit 4c294c1

Please sign in to comment.