File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -21,13 +21,18 @@ export const SplashScreen = () => {
2121 try {
2222 setStatusText ( 'Checking for updates...' ) ;
2323 console . log ( 'Update check' ) ;
24+ await new Promise ( r => setTimeout ( r , 1000 ) ) ;
2425 const update = await Updates . checkForUpdateAsync ( ) ;
26+ setStatusText ( 'ok' ) ;
2527 if ( update . isAvailable ) {
2628 console . log ( 'Dowload update' ) ;
2729 setStatusText ( 'Downloading new app version...' ) ;
2830 await Updates . fetchUpdateAsync ( ) ;
31+ console . log ( 'Restarting app' ) ;
2932 setStatusText ( 'Restarting app...' ) ;
30- await Updates . reloadAsync ( ) ;
33+ Updates . reloadAsync ( )
34+ . then ( ( r ) => console . log ( 'Restart triggered' , r ) )
35+ . catch ( ( e ) => console . error ( 'Restarting failed' , e ) ) ;
3136 }
3237 } catch ( e ) {
3338 // Ignore error, just start with unupdated version
You can’t perform that action at this time.
0 commit comments