mirror of
https://github.com/voideditor/void
synced 2026-05-23 09:28:23 +00:00
fix autoupdate
This commit is contained in:
parent
458a5160b0
commit
657e752987
1 changed files with 5 additions and 10 deletions
|
|
@ -79,18 +79,13 @@ class VoidUpdateWorkbenchContribution extends Disposable implements IWorkbenchCo
|
|||
}
|
||||
|
||||
// check once 5 seconds after mount
|
||||
this._register({
|
||||
dispose: () => clearTimeout(
|
||||
setTimeout(() => autoCheck(), 5 * 1000)
|
||||
)
|
||||
})
|
||||
|
||||
const initId = setTimeout(() => autoCheck(), 5 * 1000)
|
||||
this._register({ dispose: () => clearTimeout(initId) })
|
||||
|
||||
// check every 3 hours
|
||||
this._register({
|
||||
dispose: () => clearInterval(
|
||||
setInterval(() => autoCheck(), 3 * 60 * 60 * 1000)
|
||||
)
|
||||
})
|
||||
const intervalId = setInterval(() => autoCheck(), 3 * 60 * 60 * 1000)
|
||||
this._register({ dispose: () => clearInterval(intervalId) })
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue