File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -131,18 +131,18 @@ export default class WebPlatform extends VectorBasePlatform {
131
131
console . log ( "startUpdater, current version is " + this . getNormalizedAppVersion ( process . env . VERSION ) ) ;
132
132
this . pollForUpdate ( ( version : string , newVersion : string ) => {
133
133
const query = parseQs ( location ) ;
134
- if ( query . updated === "1" ) {
134
+ if ( query . updated ) {
135
135
console . log ( "Update reloaded but still on an old version, stopping" ) ;
136
136
// We just reloaded already and are still on the old version!
137
137
// Show the toast rather than reload in a loop.
138
138
showUpdateToast ( version , newVersion ) ;
139
139
return ;
140
140
}
141
141
142
- // Set updated=1 as a query param so we can detect that we've already done this once
143
- // and reload the page.
142
+ // Set updated as a cachebusting query param and reload the page.
144
143
const url = new URL ( window . location . href ) ;
145
- url . searchParams . set ( "updated" , "1" ) ;
144
+ url . searchParams . set ( "updated" , newVersion ) ;
145
+ console . log ( "Update reloading to " + url . toString ( ) ) ;
146
146
window . location . href = url . toString ( ) ;
147
147
} ) ;
148
148
setInterval ( ( ) => this . pollForUpdate ( showUpdateToast , hideUpdateToast ) , POKE_RATE_MS ) ;
You can’t perform that action at this time.
0 commit comments