diff --git a/lib/services/address/index.js b/lib/services/address/index.js index bee7a4a6..2e56324a 100644 --- a/lib/services/address/index.js +++ b/lib/services/address/index.js @@ -202,8 +202,6 @@ AddressService.prototype.getAddressHistory = function(addresses, options, stream self._streamAddressSummary(address, options, function(err, tx){ - results.totalCount++; - if(err) return log.error(err); @@ -226,6 +224,7 @@ AddressService.prototype.getAddressHistory = function(addresses, options, stream //sort items in desc block-height, then asc txid (if same height) results.items.sort((a, b) => b.__height - a.__height || a.txid().localeCompare(b.txid())); + results.totalCount = parseInt(results.totalCount.toFixed()); //TODO: sorting of tx list (results.items) callback(null, results);