Skip to content

Commit

Permalink
refactor: misc (#25)
Browse files Browse the repository at this point in the history
  • Loading branch information
2nthony authored Oct 26, 2021
1 parent f586f5a commit 6552b63
Show file tree
Hide file tree
Showing 6 changed files with 88 additions and 1,114 deletions.
5 changes: 2 additions & 3 deletions client/src/helper/checkUpdate.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ import { ipc } from '../ipc'
import { compareVersion } from '../util/compareVersion'
import pkg from '../../../package.json'
import { ticker } from '../util/ticker'
import { onDestroy } from 'svelte'
import { now, useEventListener } from '@svelte-use/core'
import { now, tryOnDestroy, useEventListener } from '@svelte-use/core'

const appVersion = pkg.version

Expand Down Expand Up @@ -50,7 +49,7 @@ export function checkUpdate() {
}
})

onDestroy(() => {
tryOnDestroy(() => {
checkUpdateTicker.stopTicker()
})
}
Loading

0 comments on commit 6552b63

Please sign in to comment.