diff --git a/guide/periodic-sw-updates.md b/guide/periodic-sw-updates.md index b33f948..c206510 100644 --- a/guide/periodic-sw-updates.md +++ b/guide/periodic-sw-updates.md @@ -49,7 +49,7 @@ const intervalMS = 60 * 60 * 1000 const updateSW = registerSW({ onRegisteredSW(swUrl, r) { r && setInterval(async () => { - if (!(!r.installing && navigator)) + if (r.installing || !navigator) return if (('connection' in navigator) && !navigator.onLine)