Skip to content

Commit

Permalink
console: Add common aliases for console methods
Browse files Browse the repository at this point in the history
  • Loading branch information
aks- committed Oct 21, 2015
1 parent 8d9069a commit cfa5c51
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions lib/console.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ Console.prototype.log = function() {
Console.prototype.info = Console.prototype.log;


Console.prototype.debug = Console.prototype.log;


Console.prototype.warn = function() {
this._stderr.write(util.format.apply(this, arguments) + '\n');
};
Expand All @@ -48,6 +51,9 @@ Console.prototype.warn = function() {
Console.prototype.error = Console.prototype.warn;


Console.prototype.exception = Console.prototype.warn;


Console.prototype.dir = function(object, options) {
this._stdout.write(util.inspect(object, util._extend({
customInspect: false
Expand Down

0 comments on commit cfa5c51

Please sign in to comment.