Skip to content

Commit

Permalink
fix data. handling
Browse files Browse the repository at this point in the history
  • Loading branch information
matiu committed Nov 13, 2017
1 parent 136755f commit 72827b1
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions lib/addresses.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,14 @@ AddressController.prototype.show = function(req, res) {
}

this._address.getAddressSummary(req.addr, options, function(err, data) {

if (data.addrStr)
data.addrStr = self.common.translateOutputAddress(data.addrStr);

if(err) {
return self.common.handleErrors(err, res);
}

if (data && data.addrStr)
data.addrStr = self.common.translateOutputAddress(data.addrStr);


res.jsonp(data);
});
};
Expand Down

0 comments on commit 72827b1

Please sign in to comment.