Skip to content

Commit

Permalink
Fix benchmark parallel in Node 6
Browse files Browse the repository at this point in the history
Node 6 recently changed callbacks omitted to throw. There are
actually discussions about warning instead now but for now this
fixes the benchmarks.

Fixes #1165
  • Loading branch information
benjamingr committed Aug 29, 2016
1 parent 5a381ab commit d571cc9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion benchmark/lib/dummy.js
Expand Up @@ -2,7 +2,7 @@
// with the callback at the Nth position
exports.dummy = function dummy(n) {
return function dummy_n() {
var cb = arguments[n - 1];
var cb = arguments[n - 1] || function(){};
if (global.asyncTime)
setTimeout(cb, global.asyncTime || 100);
else
Expand Down

0 comments on commit d571cc9

Please sign in to comment.