更新serviceworker逻辑

This commit is contained in:
lloydzhou
2024-07-16 16:37:55 +08:00
parent 4b84fb328c
commit eb7c7cdcb6
2 changed files with 9 additions and 1 deletions

View File

@@ -7,6 +7,7 @@ self.addEventListener("activate", function (event) {
});
self.addEventListener("install", function (event) {
self.skipWaiting(); // 立即启用新的版本
event.waitUntil(
caches.open(CHATGPT_NEXT_WEB_CACHE).then(function (cache) {
return cache.addAll([]);