fix bad return for addr txs.
This commit is contained in:
parent
61856ab68d
commit
7767bdd828
|
@ -436,6 +436,12 @@ Bitcoin.prototype.getAddrTransactions = function(addr, callback) {
|
|||
return bitcoindjs.getAddrTransactions(addr, function(err, addr) {
|
||||
if (err) return callback(err);
|
||||
addr = bitcoin.addr(addr);
|
||||
if (!addr.tx[0].out[0]) {
|
||||
return callback(null, bitcoin.addr({
|
||||
address: addr.address,
|
||||
tx: []
|
||||
}));
|
||||
}
|
||||
Bitcoin._addrCache[addr.address] = {
|
||||
addr: addr,
|
||||
time: Date.now()
|
||||
|
|
Loading…
Reference in New Issue