diff --git a/.idea/misc.xml b/.idea/misc.xml index 7c7709e01ee2155b7c0a4e707b518b02f2274eb5..f967d638a7fcfd76693951f28f989c088f769539 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -6,5 +6,5 @@ <component name="NodePackageJsonFileManager"> <packageJsonPaths /> </component> - <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.7 (school-apps)" project-jdk-type="Python SDK" /> + <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.7 (SchoolApps)" project-jdk-type="Python SDK" /> </project> \ No newline at end of file diff --git a/.idea/school-apps.iml b/.idea/school-apps.iml index d0b5ddd7b4dbd80e5134ef103cfcf8264785005a..8ae0a0d37de9163e501dbe8e71a7ad51f0a0dcde 100644 --- a/.idea/school-apps.iml +++ b/.idea/school-apps.iml @@ -23,7 +23,7 @@ <excludeFolder url="file://$MODULE_DIR$/env" /> <excludeFolder url="file://$MODULE_DIR$/schoolapps/staticcollect" /> </content> - <orderEntry type="jdk" jdkName="Python 3.7 (school-apps)" jdkType="Python SDK" /> + <orderEntry type="jdk" jdkName="Python 3.7 (SchoolApps)" jdkType="Python SDK" /> <orderEntry type="sourceFolder" forTests="false" /> </component> <component name="TemplatesService"> diff --git a/schoolapps/static/common/serviceworker.js b/schoolapps/static/common/serviceworker.js index 74403d78f6e9dddb80d31a36dbfeedcd36eddb10..db813240339b6c532fde8e9a0429bb3e26a36253 100644 --- a/schoolapps/static/common/serviceworker.js +++ b/schoolapps/static/common/serviceworker.js @@ -9,7 +9,8 @@ const precacheFiles = [ const offlineFallbackPage = '/offline'; -const networkFirstPaths = [ +const cacheFirstPaths = [ + '/faq', ]; const avoidCachingPaths = [ @@ -69,10 +70,10 @@ self.addEventListener("activate", function (event) { self.addEventListener("fetch", function (event) { if (event.request.method !== "GET") return; - if (comparePaths(event.request.url, networkFirstPaths)) { - networkFirstFetch(event); - } else { + if (comparePaths(event.request.url, cacheFirstPaths)) { cacheFirstFetch(event); + } else { + networkFirstFetch(event); } });