Skip to content

Commit

Permalink
[fix] Filter out the dead sparks
Browse files Browse the repository at this point in the history
Fixes #13
  • Loading branch information
lpinca committed Oct 16, 2015
1 parent 1afdc86 commit 780c235
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions omega.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@ module.exports = function forwards(primus) {
if (err) return fn(err);

servers = servers.reduce(function fn(memo, address, i) {
//
// Filter out the dead sparks.
//
if (!address) return memo;

memo[address] = memo[address] || [];
memo[address].push(ids[i]);

Expand Down

0 comments on commit 780c235

Please sign in to comment.