mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-23 19:45:05 +01:00
ask the new version to the new and not old service worker
This commit is contained in:
parent
73c433ec3d
commit
2de61c5928
@ -94,7 +94,7 @@ export class ServiceWorkerHandler {
|
|||||||
if (document.hidden) {
|
if (document.hidden) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const version = await this._sendAndWaitForReply("version");
|
const version = await this._sendAndWaitForReply("version", null, this._registration.waiting);
|
||||||
if (confirm(`Version ${version.version} (${version.buildHash}) is available. Reload to apply?`)) {
|
if (confirm(`Version ${version.version} (${version.buildHash}) is available. Reload to apply?`)) {
|
||||||
// prevent any fetch requests from going to the service worker
|
// prevent any fetch requests from going to the service worker
|
||||||
// from any client, so that it is not kept active
|
// from any client, so that it is not kept active
|
||||||
|
Loading…
Reference in New Issue
Block a user