Skip to content

Commit

Permalink
fix(frontend): fix update check timer
Browse files Browse the repository at this point in the history
  • Loading branch information
ravenclaw900 committed Apr 3, 2022
1 parent 9632147 commit 523087e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/frontend/src/App.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,9 @@
const updateCheck = () => {
if (
localStorage.getItem("update-check") == null ||
JSON.parse(localStorage.getItem("update-check")).lastChecked >
Math.round(Date.now() / 1000) + 86400
JSON.parse(localStorage.getItem("update-check")).lastChecked +
86400 <
Math.round(Date.now() / 1000)
) {
fetch(
"https://api.github.com/repos/ravenclaw900/DietPi-Dashboard/releases/latest"
Expand Down

0 comments on commit 523087e

Please sign in to comment.