1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-03 19:36:25 +02:00

Fix cannot update (#5890)

This commit is contained in:
tamaina
2020-02-09 12:47:50 +09:00
committed by GitHub
parent 45cb5ff4ef
commit cc72f91465
3 changed files with 26 additions and 2 deletions

View File

@@ -0,0 +1,20 @@
doctype html
html
script.
localStorage.removeItem('locale');
try {
navigator.serviceWorker.controller.postMessage('clear');
navigator.serviceWorker.getRegistrations().then(registrations => {
return Promise.all(registrations.map(registration => registration.unregister()));
}).then(() => {
location = '/';
});
} catch (e) {
console.error(e);
setTimeout(() => {
location = '/';
}, 10000)
}