@@ -450,8 +450,7 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
450
450
const withPrebuild = WithPrebuild . is ( this . state . workspace ?. context ) ;
451
451
let phase : StartPhase | undefined = StartPhase . Preparing ;
452
452
let title = undefined ;
453
- let isTimedOut = false ;
454
- let isStoppingOrStopped = false ;
453
+ let isStoppingOrStoppedPhase = false ;
455
454
let isError = error ? true : false ;
456
455
let statusMessage = ! ! error ? undefined : < p className = "text-base text-gray-400" > Preparing workspace …</ p > ;
457
456
const contextURL = ContextURL . getNormalizedURL ( this . state . workspace ) ?. toString ( ) ;
@@ -627,7 +626,7 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
627
626
628
627
// Stopping means that the workspace is currently shutting down. It could go to stopped every moment.
629
628
case "stopping" :
630
- isStoppingOrStopped = true ;
629
+ isStoppingOrStoppedPhase = true ;
631
630
if ( isPrebuild ) {
632
631
return (
633
632
< StartPage title = "Prebuild in Progress" >
@@ -665,7 +664,7 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
665
664
666
665
// Stopped means the workspace ended regularly because it was shut down.
667
666
case "stopped" :
668
- isStoppingOrStopped = true ;
667
+ isStoppingOrStoppedPhase = true ;
669
668
phase = StartPhase . Stopped ;
670
669
if ( this . state . hasImageBuildLogs ) {
671
670
const restartWithDefaultImage = ( event : React . MouseEvent ) => {
@@ -683,7 +682,6 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
683
682
}
684
683
if ( ! isPrebuild && this . state . workspaceInstance . status . conditions . timeout ) {
685
684
title = "Timed Out" ;
686
- isTimedOut = true ;
687
685
}
688
686
statusMessage = (
689
687
< div >
@@ -721,7 +719,7 @@ export default class StartWorkspace extends React.Component<StartWorkspaceProps,
721
719
phase = { phase }
722
720
error = { error }
723
721
title = { title }
724
- showLatestIdeWarning = { isError || ( ! isTimedOut && ! isStoppingOrStopped && useLatest ) }
722
+ showLatestIdeWarning = { useLatest && ( isError || ! isStoppingOrStoppedPhase ) }
725
723
>
726
724
{ statusMessage }
727
725
</ StartPage >
0 commit comments