Skip to content

Commit

Permalink
Merge pull request #26 from calebsmithdev/updater
Browse files Browse the repository at this point in the history
Updated changes
  • Loading branch information
calebsmithdev authored Dec 3, 2024
2 parents 1fa8f72 + 13e5bee commit 428bb6e
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions src/composables/useUpdater.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,17 @@ export default function useUpdater() {
}
}

onMounted(() => {
emit('tauri://update')
onMounted(async () => {
const update = await check();
if (update) {
updateNeeded.value = true
}

setInterval(() => {
emit("tauri://update")
setInterval(async () => {
const update = await check();
if (update) {
updateNeeded.value = true
}
}, 5 * 60 * 1000)

listen('tauri://update-available', function (res) {
Expand Down

0 comments on commit 428bb6e

Please sign in to comment.