diff --git a/public/serviceworker.js b/public/serviceworker.js deleted file mode 100644 index 1eb9b19f82..0000000000 --- a/public/serviceworker.js +++ /dev/null @@ -1,58 +0,0 @@ -/* - * serviceworker.js - * Copyright (c) 2021 james@firefly-iii.org - * - * This file is part of Firefly III (https://github.com/firefly-iii). - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License as - * published by the Free Software Foundation, either version 3 of the - * License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License - * along with this program. If not, see . - */ - -let staticCachePrefix = "firefly-III-" -let staticCacheName = staticCachePrefix + new Date().getTime(); -let cachedFiles = [ - '/offline', - '/v2/plugins/local-fonts/gf-source.css', - '/v2/css/app.css', -]; - -// Create cache on install -self.addEventListener("install", event => { - this.skipWaiting(); - event.waitUntil( - caches.open(staticCacheName).then(cache => cache.addAll(cachedFiles)) - ) -}); - -// Clear cache on activate -self.addEventListener('activate', event => { - event.waitUntil( - caches.keys().then(cacheNames => { - return Promise.all( - cacheNames - .filter(cacheName => (cacheName.startsWith(staticCachePrefix))) - .filter(cacheName => (cacheName !== staticCacheName)) - .map(cacheName => caches.delete(cacheName)) - ); - }) - ); -}); - -// Serve from Cache or return the offline page -self.addEventListener("fetch", event => { - event.respondWith( - caches.match(event.request) - .then(response => (response || fetch(event.request))) - .catch(() => caches.match('offline')) - ) -}); diff --git a/resources/views/layout/default.twig b/resources/views/layout/default.twig index 555140d32c..aedf826479 100644 --- a/resources/views/layout/default.twig +++ b/resources/views/layout/default.twig @@ -228,17 +228,6 @@ {% endif %} - diff --git a/resources/views/layout/empty.twig b/resources/views/layout/empty.twig index c72672279f..516e82c9f7 100644 --- a/resources/views/layout/empty.twig +++ b/resources/views/layout/empty.twig @@ -61,17 +61,5 @@ {% endif %} - - diff --git a/resources/views/layout/guest.twig b/resources/views/layout/guest.twig index 50177b2b95..f96592aad6 100644 --- a/resources/views/layout/guest.twig +++ b/resources/views/layout/guest.twig @@ -76,17 +76,5 @@ {% endif %} - - diff --git a/resources/views/layout/install.twig b/resources/views/layout/install.twig index edb8564ca0..a4cc4e9c81 100644 --- a/resources/views/layout/install.twig +++ b/resources/views/layout/install.twig @@ -36,17 +36,5 @@ {% block scripts %}{% endblock %} - -