summaryrefslogtreecommitdiff
path: root/perf
diff options
context:
space:
mode:
authorAlexander Early <aearly@fluid.com>2015-05-31 18:41:24 -0700
committerAlexander Early <aearly@fluid.com>2015-05-31 18:41:24 -0700
commit7889ed3fbf20d8b2f57d903d942e304672e67c69 (patch)
treea97702b777ac27d8690492df2c54ca0cae1f0eca /perf
parentbf71c8c417dea9c1fd1f6836cc573b26a572e9ce (diff)
downloadasync-7889ed3fbf20d8b2f57d903d942e304672e67c69.tar.gz
improved waterfall performance with ensureAsync
Diffstat (limited to 'perf')
-rw-r--r--perf/suites.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/perf/suites.js b/perf/suites.js
index 28b5a32..b4ea76b 100644
--- a/perf/suites.js
+++ b/perf/suites.js
@@ -148,7 +148,11 @@ module.exports = [
return cb(null, 1);
}
].concat(_.range(count).map(function (i) {
- return function (arg, cb) { cb(null, i); };
+ return function (arg, cb) {
+ setImmediate(function () {
+ cb(null, i);
+ });
+ };
}));
},
fn: function (async, done) {