invert boolean operation for readability and add comment
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
parent
0737965079
commit
be612998bd
1 changed files with 2 additions and 1 deletions
|
@ -523,8 +523,9 @@ module.exports = React.createClass({
|
||||||
selectedAddresses[addressType].add(address);
|
selectedAddresses[addressType].add(address);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Filter out any addresses in the above already selected addresses (matching both type and address)
|
||||||
const filteredSuggestedList = this.state.suggestedList.filter(({address, addressType}) => {
|
const filteredSuggestedList = this.state.suggestedList.filter(({address, addressType}) => {
|
||||||
return !selectedAddresses[addressType] || !selectedAddresses[addressType].has(address);
|
return !(selectedAddresses[addressType] && selectedAddresses[addressType].has(address));
|
||||||
});
|
});
|
||||||
|
|
||||||
const query = [];
|
const query = [];
|
||||||
|
|
Loading…
Reference in a new issue