diff options
| author | AAGaming <aa@mail.catvibers.me> | 2022-08-09 21:52:03 -0400 |
|---|---|---|
| committer | AAGaming <aa@mail.catvibers.me> | 2022-08-09 21:52:03 -0400 |
| commit | 67426af3ef73e788d99b6d2e0c730c270daea273 (patch) | |
| tree | 30c1f4b33e63d38d8d5cc26f26af655f1b5a44ba /backend | |
| parent | 0dbdb4a143f6e4f2b08c5a38a597d5a1c49a109c (diff) | |
| download | decky-loader-67426af3ef73e788d99b6d2e0c730c270daea273.tar.gz decky-loader-67426af3ef73e788d99b6d2e0c730c270daea273.zip | |
Add api for showing toast notificationsv2.0.4-67426af-pre
Diffstat (limited to 'backend')
| -rw-r--r-- | backend/updater.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/backend/updater.py b/backend/updater.py index 4c3cd715..4fca0496 100644 --- a/backend/updater.py +++ b/backend/updater.py @@ -62,7 +62,7 @@ class Updater: "updatable": self.localVer != None } else: - return {"current": "unknown", "updatable": False} + return {"current": "unknown", "remote": self.remoteVer, "updatable": False} async def check_for_updates(self): async with ClientSession() as web: @@ -70,6 +70,8 @@ class Updater: remoteVersions = await res.json() self.remoteVer = next(filter(lambda ver: ver["prerelease"] and ver["tag_name"].startswith("v") and ver["tag_name"].endswith("-pre"), remoteVersions), None) logger.info("Updated remote version information") + tab = await get_tab("SP") + await tab.evaluate_js(f"window.DeckyPluginLoader.notifyUpdates()", False, True, False) return await self.get_version() async def version_reloader(self): @@ -79,7 +81,7 @@ class Updater: await self.check_for_updates() except: pass - await sleep(60 * 60) # 1 hour + await sleep(60 * 60 * 6) # 6 hours async def do_update(self): version = self.remoteVer["tag_name"] |
