From a2121ef73eaf7bd0a2c38fe4f93588d0077f7c57 Mon Sep 17 00:00:00 2001 From: Matthew Fosse Date: Wed, 17 Jul 2024 14:59:25 -0700 Subject: [PATCH] save --- cw_bitcoin/lib/litecoin_wallet.dart | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/cw_bitcoin/lib/litecoin_wallet.dart b/cw_bitcoin/lib/litecoin_wallet.dart index 5cfb46709..505ff9d8e 100644 --- a/cw_bitcoin/lib/litecoin_wallet.dart +++ b/cw_bitcoin/lib/litecoin_wallet.dart @@ -179,19 +179,19 @@ abstract class LitecoinWalletBase extends ElectrumWallet with Store { syncStatus = SyncedSyncStatus(); } - // if (resp.mwebUtxosHeight > mwebUtxosHeight) { - // mwebUtxosHeight = resp.mwebUtxosHeight; - // await checkMwebUtxosSpent(); - // // update the confirmations for each transaction: - // for (final transaction in transactionHistory.transactions.values) { - // if (transaction.isPending) continue; - // final confirmations = mwebUtxosHeight - transaction.height + 1; - // if (transaction.confirmations == confirmations) continue; - // transaction.confirmations = confirmations; - // transactionHistory.addOne(transaction); - // } - // await transactionHistory.save(); - // } + if (resp.mwebUtxosHeight > mwebUtxosHeight) { + mwebUtxosHeight = resp.mwebUtxosHeight; + await checkMwebUtxosSpent(); + // update the confirmations for each transaction: + for (final transaction in transactionHistory.transactions.values) { + if (transaction.isPending) continue; + final confirmations = mwebUtxosHeight - transaction.height + 1; + if (transaction.confirmations == confirmations) continue; + transaction.confirmations = confirmations; + transactionHistory.addOne(transaction); + } + await transactionHistory.save(); + } } }); processMwebUtxos();