Skip to content

Commit dbfa1b0

Browse files
committed
added sets
1 parent 6ae199c commit dbfa1b0

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

src/sw.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,13 @@ const otherManifest = [
2626
},
2727
];
2828

29-
const allManifestURLs = [...manifest, ...otherManifest].map(
30-
(entry) => new URL(entry.url, self.location).href,
31-
);
32-
29+
const allManifestURLs = [
30+
new Set(
31+
[...manifest, ...otherManifest].map(
32+
(entry) => new URL(entry.url, self.location).href,
33+
),
34+
),
35+
];
3336
self.addEventListener("install", (event) => {
3437
event.waitUntil(
3538
(async () => {

0 commit comments

Comments
 (0)