File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -696,6 +696,7 @@ impl<S: MutinyStorage> NodeManager<S> {
696696 }
697697
698698 // check keychain size
699+ let start = Instant :: now ( ) ;
699700 let changes = match nm. storage . read_changes ( ) {
700701 Ok ( Some ( c) ) => c,
701702 Ok ( None ) => ChangeSet :: default ( ) ,
@@ -729,7 +730,7 @@ impl<S: MutinyStorage> NodeManager<S> {
729730 . is_ok ( )
730731 {
731732 if let Ok ( mut wallet) = nm. wallet . wallet . try_write ( ) {
732- if let Some ( changeset) = wallet . take_staged ( ) {
733+ if let Some ( changeset) = new_wallet . take_staged ( ) {
733734 if nm. storage . restore_changes ( & changeset) . is_ok ( ) {
734735 * wallet = new_wallet;
735736 log_info ! (
@@ -748,6 +749,11 @@ impl<S: MutinyStorage> NodeManager<S> {
748749 }
749750 }
750751 }
752+ log_info ! (
753+ nm. logger,
754+ "Keychain compaction took {} seconds" ,
755+ start. elapsed( ) . as_secs( )
756+ ) ;
751757
752758 // wait for next sync round, checking graceful shutdown check each second.
753759 if !did_keychain_compact_this_round {
You can’t perform that action at this time.
0 commit comments