Skip to content

Commit

Permalink
util: speed up common case of formatting string
Browse files Browse the repository at this point in the history
PR-URL: #1749
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
  • Loading branch information
ChALkeR authored and bnoordhuis committed May 20, 2015
1 parent 9b35be5 commit 214d020
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/util.js
Expand Up @@ -13,6 +13,8 @@ exports.format = function(f) {
return objects.join(' ');
}

if (arguments.length === 1) return f;

var i = 1;
var args = arguments;
var len = args.length;
Expand Down

0 comments on commit 214d020

Please sign in to comment.