Permalink
Browse files

check for null meta value and default it to empty object

  • Loading branch information...
1 parent 626b293 commit bc257bb6f8a40d8b7d27741d47981502495568fe @dlasky dlasky committed Mar 8, 2013
Showing with 6 additions and 1 deletion.
  1. +6 −1 lib/winston-statsd.js
View
@@ -119,6 +119,11 @@ Statsd.prototype.log = function (level, msg, meta, callback) {
meta = {};
}
+ //
+ // support optional meta
+ //
+ meta = meta || {};
+
//
// ignore message if we are silent
//
@@ -247,4 +252,4 @@ Statsd.prototype.log = function (level, msg, meta, callback) {
}
this.emit('logged');
-};
+};

0 comments on commit bc257bb

Please sign in to comment.