fastparallel
Advanced tools
Comparing version 1.3.0 to 1.3.1
{ | ||
"name": "fastparallel", | ||
"version": "1.3.0", | ||
"version": "1.3.1", | ||
"description": "Zero-overhead asynchronous parallel/each/map function call", | ||
@@ -5,0 +5,0 @@ "main": "parallel.js", |
@@ -21,3 +21,3 @@ var xtend = require('xtend') | ||
if (toCall.length === 0) { | ||
done() | ||
done.call(that) | ||
released(last) | ||
@@ -24,0 +24,0 @@ } else { |
11
test.js
@@ -202,1 +202,12 @@ var test = require('tape') | ||
}) | ||
test('call the callback with the given this with no data', function (t) { | ||
t.plan(1) | ||
var instance = parallel() | ||
var obj = {} | ||
instance(obj, [], 42, function done () { | ||
t.equal(obj, this, 'this matches') | ||
}) | ||
}) |
13229
354