diff --git a/packages/flutter_tools/templates/app/web/index.html.tmpl b/packages/flutter_tools/templates/app/web/index.html.tmpl index d771b1ba56..800fb35795 100644 --- a/packages/flutter_tools/templates/app/web/index.html.tmpl +++ b/packages/flutter_tools/templates/app/web/index.html.tmpl @@ -67,7 +67,7 @@ if (!reg.active && (reg.installing || reg.waiting)) { // No active web worker and we have installed or are installing // one for the first time. Simply wait for it to activate. - waitForActivation(reg.installing ?? reg.waiting); + waitForActivation(reg.installing || reg.waiting); } else if (!reg.active.scriptURL.endsWith(serviceWorkerVersion)) { // When the app updates the serviceWorkerVersion changes, so we // need to ask the service worker to update.