@@ -632,8 +632,9 @@ pub(crate) async fn handle_online_wallet_subcommand(
632632 client
633633 . populate_tx_cache ( wallet. tx_graph ( ) . full_txs ( ) . map ( |tx_node| tx_node. tx ) ) ;
634634
635- let update = client. full_scan ( request, _stop_gap, * batch_size, false ) ?;
636- wallet. apply_update ( update) ?;
635+ let update = client. full_scan ( request, _stop_gap, batch_size, false ) ?;
636+ let wallet_events = wallet. apply_update_events ( update) ?;
637+ print_wallet_events ( & wallet_events) ;
637638 }
638639 #[ cfg( feature = "esplora" ) ]
639640 Esplora {
@@ -644,7 +645,8 @@ pub(crate) async fn handle_online_wallet_subcommand(
644645 . full_scan ( request, _stop_gap, * parallel_requests)
645646 . await
646647 . map_err ( |e| * e) ?;
647- wallet. apply_update ( update) ?;
648+ let wallet_events = wallet. apply_update_events ( update) ?;
649+ print_wallet_events ( & wallet_events) ;
648650 }
649651
650652 #[ cfg( feature = "rpc" ) ]
@@ -1524,10 +1526,12 @@ pub async fn sync_wallet(client: &BlockchainClient, wallet: &mut Wallet) -> Resu
15241526 // already have.
15251527 client. populate_tx_cache ( wallet. tx_graph ( ) . full_txs ( ) . map ( |tx_node| tx_node. tx ) ) ;
15261528
1527- let update = client. sync ( request, * batch_size, false ) ?;
1528- wallet
1529- . apply_update ( update)
1530- . map_err ( |e| Error :: Generic ( e. to_string ( ) ) )
1529+ let update = client. sync ( request, batch_size, false ) ?;
1530+ let wallet_events = wallet
1531+ . apply_update_events ( update)
1532+ . map_err ( |e| Error :: Generic ( e. to_string ( ) ) ) ?;
1533+ print_wallet_events ( & wallet_events) ;
1534+ Ok ( ( ) )
15311535 }
15321536 #[ cfg( feature = "esplora" ) ]
15331537 Esplora {
@@ -1538,9 +1542,11 @@ pub async fn sync_wallet(client: &BlockchainClient, wallet: &mut Wallet) -> Resu
15381542 . sync ( request, * parallel_requests)
15391543 . await
15401544 . map_err ( |e| * e) ?;
1541- wallet
1542- . apply_update ( update)
1543- . map_err ( |e| Error :: Generic ( e. to_string ( ) ) )
1545+ let wallet_events = wallet
1546+ . apply_update_events ( update)
1547+ . map_err ( |e| Error :: Generic ( e. to_string ( ) ) ) ?;
1548+ print_wallet_events ( & wallet_events) ;
1549+ Ok ( ( ) )
15441550 }
15451551 #[ cfg( feature = "rpc" ) ]
15461552 RpcClient { client } => {
0 commit comments