Skip to content

Commit

Permalink
e
Browse files Browse the repository at this point in the history
  • Loading branch information
ThinLiquid committed Sep 1, 2024
1 parent 535845c commit c3b9930
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,9 @@ function checkIsSafari (): boolean {

window.isSafari = checkIsSafari()

const updateSW = registerSW({
onNeedRefresh () {
updateSW(true).catch(e => {
console.error('Failed to update service worker:', e)
})
}
const updateSW = registerSW()
updateSW(true).catch(e => {
console.error('Failed to update service worker:', e)
})

window.onload = async () => { await updateSW() }
Expand Down

0 comments on commit c3b9930

Please sign in to comment.