File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -81,15 +81,19 @@ export const handleCheckBlockReplayProgress = (
8181 { progress : finalProgressPercentage , type : progressType } ,
8282 mainWindow . webContents
8383 ) ;
84+
85+ if ( finalProgressPercentage === 100 && progressType === 'pushingLedger' ) {
86+ clearInterval ( checkBlockReplayProgressInterval ) ;
87+ }
8488 } ;
8589
8690 const setBlockReplayProgressCheckingInterval = ( ) => {
87- setInterval ( async ( ) => {
91+ return setInterval ( async ( ) => {
8892 checkBlockReplayProgress ( ) ;
8993 } , BLOCK_REPLAY_PROGRESS_CHECK_INTERVAL ) ;
9094 } ;
9195
9296 // Start default interval
93- setBlockReplayProgressCheckingInterval ( ) ;
97+ const checkBlockReplayProgressInterval = setBlockReplayProgressCheckingInterval ( ) ;
9498 return checkBlockReplayProgress ;
9599} ;
You can’t perform that action at this time.
0 commit comments