Commit 15d8e53d authored by Kévin Dunglas's avatar Kévin Dunglas Committed by Dan Abramov
Browse files

Remove an useless negation in registerServiceWorker.js (#3150)

parent 70e0c08e
Showing with 4 additions and 4 deletions
+4 -4
...@@ -32,12 +32,12 @@ export default function register() { ...@@ -32,12 +32,12 @@ export default function register() {
window.addEventListener('load', () => { window.addEventListener('load', () => {
const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`; const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;
if (!isLocalhost) { if (isLocalhost) {
// Is not local host. Just register service worker
registerValidSW(swUrl);
} else {
// This is running on localhost. Lets check if a service worker still exists or not. // This is running on localhost. Lets check if a service worker still exists or not.
checkValidServiceWorker(swUrl); checkValidServiceWorker(swUrl);
} else {
// Is not local host. Just register service worker
registerValidSW(swUrl);
} }
}); });
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment