summaryrefslogtreecommitdiff
path: root/backend/main.py
diff options
context:
space:
mode:
authorAAGaming <aa@mail.catvibers.me>2022-08-14 12:51:07 -0400
committerAAGaming <aa@mail.catvibers.me>2022-08-14 12:51:07 -0400
commita4e2237fc024c89861e36b83a42c10ad50274641 (patch)
treedb563af45354ec4bcac4a52a69a4145e99152f81 /backend/main.py
parent85d0398e6203de85963051a9b7aa0efd906e7664 (diff)
downloaddecky-loader-a4e2237fc024c89861e36b83a42c10ad50274641.tar.gz
decky-loader-a4e2237fc024c89861e36b83a42c10ad50274641.zip
fix loader not re-injecting on restart
Diffstat (limited to 'backend/main.py')
-rw-r--r--backend/main.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/backend/main.py b/backend/main.py
index 21d4f5a0..5132d6b1 100644
--- a/backend/main.py
+++ b/backend/main.py
@@ -97,12 +97,13 @@ class PluginManager:
#await inject_to_tab("SP", "window.syncDeckyPlugins();")
async def loader_reinjector(self):
- await sleep(5)
+ check_if_loaded = False
while True:
await sleep(5)
- if not await tab_has_global_var("SP", "deckyHasLoaded"):
+ if not check_if_loaded or not await tab_has_global_var("SP", "deckyHasLoaded"):
logger.info("Plugin loader isn't present in Steam anymore, reinjecting...")
await self.inject_javascript()
+ check_if_loaded = True
async def inject_javascript(self, request=None):
try: