mirror of
https://github.com/basicswap/basicswap.git
synced 2025-01-03 17:29:26 +00:00
coins: Fix getoutput for v18 cores.
This commit is contained in:
parent
e3033799b0
commit
3217918f7c
1 changed files with 4 additions and 1 deletions
|
@ -888,7 +888,10 @@ class BTCInterface(CoinInterface):
|
|||
def getOutput(self, txid, dest_script, expect_value):
|
||||
# TODO: Use getrawtransaction if txindex is active
|
||||
utxos = self.rpc_callback('scantxoutset', ['start', ['raw({})'.format(dest_script.hex())]])
|
||||
chain_height = utxos['height']
|
||||
if 'height' in utxos: # chain_height not returned by v18 codebase
|
||||
chain_height = utxos['height']
|
||||
else:
|
||||
chain_height = self.getChainHeight()
|
||||
rv = []
|
||||
for utxo in utxos['unspents']:
|
||||
if txid and txid.hex() != utxo['txid']:
|
||||
|
|
Loading…
Reference in a new issue