@@ -717,12 +717,15 @@ class AddressSynchronizer(PrintError):
|
|||||||
return None
|
return None
|
||||||
if hasattr(tx, '_cached_fee'):
|
if hasattr(tx, '_cached_fee'):
|
||||||
return tx._cached_fee
|
return tx._cached_fee
|
||||||
is_relevant, is_mine, v, fee = self.get_wallet_delta(tx)
|
with self.lock, self.transaction_lock:
|
||||||
if fee is None:
|
is_relevant, is_mine, v, fee = self.get_wallet_delta(tx)
|
||||||
txid = tx.txid()
|
if fee is None:
|
||||||
fee = self.tx_fees.get(txid)
|
txid = tx.txid()
|
||||||
if fee is not None:
|
fee = self.tx_fees.get(txid)
|
||||||
tx._cached_fee = fee
|
# cache fees. if wallet is synced, cache all;
|
||||||
|
# otherwise only cache non-None, as None can still change while syncing
|
||||||
|
if self.up_to_date or fee is not None:
|
||||||
|
tx._cached_fee = fee
|
||||||
return fee
|
return fee
|
||||||
|
|
||||||
def get_addr_io(self, address):
|
def get_addr_io(self, address):
|
||||||
|
|||||||
Reference in New Issue
Block a user