mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-08-31 09:21:39 +00:00
jsondb: convert lists to sets
This commit is contained in:
parent
4b36114d0d
commit
d73f7a2c10
1 changed files with 5 additions and 4 deletions
|
@ -599,10 +599,11 @@ class JsonDB(PrintError):
|
|||
self.verified_tx = self.get_data_ref('verified_tx3') # txid -> TxMinedInfo. Access with self.lock.
|
||||
self.tx_fees = self.get_data_ref('tx_fees')
|
||||
|
||||
# tuple to set
|
||||
for txid, d in list(self.txi.items()):
|
||||
for addr, lst in d.items():
|
||||
self.txi[txid][addr] = set([tuple(x) for x in lst])
|
||||
# convert list to set
|
||||
for t in self.txi, self.txo:
|
||||
for d in t.values():
|
||||
for addr, lst in d.items():
|
||||
d[addr] = set([tuple(x) for x in lst])
|
||||
|
||||
# remove unreferenced tx
|
||||
for tx_hash in self.transactions:
|
||||
|
|
Loading…
Add table
Reference in a new issue