Skip to content

Commit

Permalink
Address Ben's PR feedback; simplify collectDampScores()
Browse files Browse the repository at this point in the history
  • Loading branch information
jwolski committed Nov 25, 2015
1 parent 8407cac commit bd181a8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/membership/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,9 @@ Membership.prototype.collectDampScores =
var self = this;
return memberAddresses.reduce(function reduce(result, address) {
var member = self.findMemberByAddress(address);
if (!member) return result;
result.push(new MemberDampScore(member.address, member.dampScore));
if (member) {
result.push(new MemberDampScore(member.address, member.dampScore));
}
return result;
}, []);
};
Expand Down

0 comments on commit bd181a8

Please sign in to comment.