blob: 00eacdf5080b60b8dee91774bbd1c84d6307b1b9 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
const debug = require('../preload-safe-debug')('Ferdium:Plugin:SessionHandler');
export class SessionHandler {
async releaseServiceWorkers() {
try {
const registrations =
await window.navigator.serviceWorker.getRegistrations();
for (const registration of registrations) {
registration.unregister();
debug('ServiceWorker unregistered');
}
} catch (error) {
debug(error);
}
}
}
|