mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-03-13 20:31:50 +08:00
15 lines
312 B
JavaScript
15 lines
312 B
JavaScript
self.addEventListener("install", () => {
|
|
self.skipWaiting();
|
|
});
|
|
|
|
self.addEventListener("activate", () => {
|
|
self.registration
|
|
.unregister()
|
|
.then(() => {
|
|
return self.clients.matchAll();
|
|
})
|
|
.then((clients) => {
|
|
clients.forEach((client) => client.navigate(client.url));
|
|
});
|
|
});
|