Skip to content

Commit

Permalink
Call callback even if keys is empty
Browse files Browse the repository at this point in the history
  • Loading branch information
markyen committed Feb 13, 2015
1 parent a27670e commit 30fab73
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -855,6 +855,10 @@ RingPop.prototype.handleOrProxyAll =
var pending = dests.length;
var responses = [];

if (pending === 0 && cb) {
return cb(null, responses);
}

dests.forEach(function(dest) {
var res = hammock.Response();
res.on('response', function(err, response) {
Expand Down

0 comments on commit 30fab73

Please sign in to comment.