Skip to content
This repository has been archived by the owner on Oct 3, 2022. It is now read-only.

Commit

Permalink
WWW/worker.js: Fix worker control scope
Browse files Browse the repository at this point in the history
  • Loading branch information
bakape committed Apr 28, 2016
1 parent b5c96d0 commit 7eff0c1
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions docs/nginx.conf.example
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ server {
location = /503.ico {}
location = /503.html {}
location /mobile {}
location /worker.js {}

# Handles static assets (images, JS, CSS, etc.)
# Set "SERVE_STATIC_FILES: false" and `MEDIA_URL` to the full path of
Expand Down
2 changes: 1 addition & 1 deletion www/js/loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ Selects and loads the client files

if ('serviceWorker' in navigator) {
navigator.serviceWorker
.register(imports.config.MEDIA_URL + "js/worker.js")
.register("/worker.js")
.catch(function (err) {
throw err
})
Expand Down
2 changes: 0 additions & 2 deletions www/js/worker.js → www/worker.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,3 @@
self.addEventListener('install', function () {})

self.addEventListener('activate', function () {})

self.addEventListener('fetch', function () {})

0 comments on commit 7eff0c1

Please sign in to comment.