Skip to content

Commit

Permalink
brackets for single if statement
Browse files Browse the repository at this point in the history
  • Loading branch information
reqshark committed Mar 16, 2015
1 parent 90ad4fb commit 4d777da
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -321,17 +321,19 @@ Socket.prototype.chan = function(){
var args = arguments;
var channels = args.length;
while(channels--) {
if (nn.Setopt(this.binding, nn.NN_SUB, nn.NN_SUB_SUBSCRIBE, args[channels]) == 0)
if (nn.Setopt(this.binding, nn.NN_SUB, nn.NN_SUB_SUBSCRIBE, args[channels]) == 0){
this.channels[args[channels]] = true;
}
};
}

Socket.prototype.rmchan = function(){
var args = arguments;
var channels = args.length;
while(channels--) {
if (nn.Setopt(this.binding, nn.NN_SUB, nn.NN_SUB_UNSUBSCRIBE, args[channels]) == 0)
if (nn.Setopt(this.binding, nn.NN_SUB, nn.NN_SUB_UNSUBSCRIBE, args[channels]) == 0){
this.channels[args[channels]] = true;
}
};
}

Expand Down

0 comments on commit 4d777da

Please sign in to comment.