ensure notification address is added to local db

This commit is contained in:
julian 2023-04-26 16:19:24 -06:00
parent 9749443472
commit 5a50f7d256

View file

@ -682,6 +682,10 @@ class BitcoinWallet extends CoinServiceAPI
// isSegwit does not matter here at all
final myCode = await getPaymentCode(isSegwit: false);
// this will add the notification address to the db if it isn't
// already there so it can be watched
await getMyNotificationAddress();
// refresh transactions to pick up any received notification transactions
await _refreshTransactions();
@ -1468,6 +1472,10 @@ class BitcoinWallet extends CoinServiceAPI
_generateAddressForChain(1, 0, DerivePathType.bip49),
]);
// this will add the notification address to the db if it isn't
// already there so it can be watched
await getMyNotificationAddress();
await db.putAddresses(initialAddresses);
Logging.instance.log("_generateNewWalletFinished", level: LogLevel.Info);