From c7ca4c8be781753f86d806015b182f1ee5443fcf Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 8 Feb 2019 16:16:40 +0100 Subject: Fix client with google bot --- client/src/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'client/src/main.ts') diff --git a/client/src/main.ts b/client/src/main.ts index dee962180..86fdabba5 100644 --- a/client/src/main.ts +++ b/client/src/main.ts @@ -34,7 +34,7 @@ const bootstrap = () => platformBrowserDynamic() // .catch(err => console.error('Cannot register service worker.', err)) // } - if (navigator.serviceWorker) { + if (navigator.serviceWorker && typeof navigator.serviceWorker.getRegistrations === 'function') { navigator.serviceWorker.getRegistrations() .then(registrations => { for (const registration of registrations) { -- cgit v1.2.3