diff options
Diffstat (limited to 'assets/js/src')
-rw-r--r-- | assets/js/src/pwa.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/assets/js/src/pwa.js b/assets/js/src/pwa.js index c3bdd7272c..5e1a43b085 100644 --- a/assets/js/src/pwa.js +++ b/assets/js/src/pwa.js @@ -5,14 +5,14 @@ if ('serviceWorker' in navigator) { window.addEventListener('load', function () { - navigator.serviceWorker.register('/sw.js').then(function (registration) { + navigator.serviceWorker.register('/sw.js').then(function (registration) { // eslint-disable-line compat/compat console.log('ServiceWorker registration successful with scope: ', registration.scope) registration.onupdatefound = function () { var installingWorker = registration.installing installingWorker.onstatechange = function () { switch (installingWorker.state) { case 'installed': - if (navigator.serviceWorker.controller) { + if (navigator.serviceWorker.controller) { // eslint-disable-line compat/compat console.log('new update available') location.reload(true) } |