mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-01-25 12:06:05 +00:00
CAKE-158 | called update() method for accountList in the _onNewBlock() and rescan() methods (monero_wallet.dart)
This commit is contained in:
parent
5787bac658
commit
e10387a1b6
1 changed files with 4 additions and 1 deletions
|
@ -98,7 +98,7 @@ abstract class MoneroWalletBase extends WalletBase<MoneroBalance> with Store {
|
||||||
bool _isSavingAfterNewTransaction;
|
bool _isSavingAfterNewTransaction;
|
||||||
|
|
||||||
Future<void> init() async {
|
Future<void> init() async {
|
||||||
await accountList.update();
|
accountList.update();
|
||||||
account = accountList.accounts.first;
|
account = accountList.accounts.first;
|
||||||
subaddressList.update(accountIndex: account.id ?? 0);
|
subaddressList.update(accountIndex: account.id ?? 0);
|
||||||
subaddress = subaddressList.getAll().first;
|
subaddress = subaddressList.getAll().first;
|
||||||
|
@ -260,6 +260,7 @@ abstract class MoneroWalletBase extends WalletBase<MoneroBalance> with Store {
|
||||||
monero_wallet.rescanBlockchainAsync();
|
monero_wallet.rescanBlockchainAsync();
|
||||||
await startSync();
|
await startSync();
|
||||||
_askForUpdateBalance();
|
_askForUpdateBalance();
|
||||||
|
accountList.update();
|
||||||
await _askForUpdateTransactionHistory();
|
await _askForUpdateTransactionHistory();
|
||||||
await save();
|
await save();
|
||||||
await walletInfo.save();
|
await walletInfo.save();
|
||||||
|
@ -369,11 +370,13 @@ abstract class MoneroWalletBase extends WalletBase<MoneroBalance> with Store {
|
||||||
if (walletInfo.isRecovery) {
|
if (walletInfo.isRecovery) {
|
||||||
await _askForUpdateTransactionHistory();
|
await _askForUpdateTransactionHistory();
|
||||||
_askForUpdateBalance();
|
_askForUpdateBalance();
|
||||||
|
accountList.update();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (blocksLeft < 100) {
|
if (blocksLeft < 100) {
|
||||||
await _askForUpdateTransactionHistory();
|
await _askForUpdateTransactionHistory();
|
||||||
_askForUpdateBalance();
|
_askForUpdateBalance();
|
||||||
|
accountList.update();
|
||||||
syncStatus = SyncedSyncStatus();
|
syncStatus = SyncedSyncStatus();
|
||||||
await _afterSyncSave();
|
await _afterSyncSave();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue