···11[package]
22name = "diffuse"
33-version = "3.4.0"
33+version = "3.5.0"
44description = "A music player that connects to your cloud/distributed storage"
55authors = ["Steven Vandevelde"]
66edition = "2021"
···99//
1010/// <reference lib="webworker" />
11111212-import { } from "../index.d"
1313-14121513const KEY =
1614 /* eslint-disable no-undef */
···19172018const EXCLUDE =
2119 [ "_headers"
2222- , "_redirects"
2323- , "CORS"
2020+ , "_redirects"
2121+ , "CORS"
2422 ]
25232624···3937// 📣
403841394242-self.addEventListener("activate", _event => {
4040+self.addEventListener("activate", () => {
4341 // Remove all caches except the one with the currently used `KEY`
4442 caches.keys().then(keys => {
4543 keys.forEach(k => {
···8280 })()
8381 )
84828585- // When doing a request with basic authentication in the url, put it in the headers instead
8383+ // When doing a request with basic authentication in the url, put it in the headers instead
8684 } else if (event.request.url.includes("service_worker_authentication=")) {
8785 const url = new URL(event.request.url)
8886 const token = url.searchParams.get("service_worker_authentication")
···9694 "Basic " + token
9795 )
98969999- // When doing a request with access token in the url, put it in the headers instead
9797+ // When doing a request with access token in the url, put it in the headers instead
10098 } else if (event.request.url.includes("bearer_token=")) {
10199 const url = new URL(event.request.url)
102100 const token = url.searchParams.get("bearer_token")
···112110 "Bearer " + token
113111 )
114112115115- // Use cache if internal request and not using native app
113113+ // Use cache if internal request and not using native app
116114 } else if (isInternal) {
117115 event.respondWith(
118116 isNativeWrapper