Browse Source

Merge pull request #695 from matiu/bug/uniq

add uniq to insight queries
feat/estimateFee-limit
Matias Alejo Garcia 8 years ago
committed by GitHub
parent
commit
5cab2a722b
  1. 4
      lib/blockchainexplorers/insight.js

4
lib/blockchainexplorers/insight.js

@ -57,7 +57,7 @@ Insight.prototype.getUtxos = function(addresses, cb) {
method: 'POST', method: 'POST',
path: this.apiPrefix + '/addrs/utxo', path: this.apiPrefix + '/addrs/utxo',
json: { json: {
addrs: [].concat(addresses).join(',') addrs: _.uniq([].concat(addresses)).join(',')
}, },
}; };
@ -116,7 +116,7 @@ Insight.prototype.getTransactions = function(addresses, from, to, cb) {
method: 'POST', method: 'POST',
path: this.apiPrefix + '/addrs/txs' + (qs.length > 0 ? '?' + qs.join('&') : ''), path: this.apiPrefix + '/addrs/txs' + (qs.length > 0 ? '?' + qs.join('&') : ''),
json: { json: {
addrs: [].concat(addresses).join(',') addrs: _.uniq([].concat(addresses)).join(',')
}, },
timeout: 120000, timeout: 120000,
}; };

Loading…
Cancel
Save