summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAAGaming <aagaming@riseup.net>2024-08-03 18:16:51 -0400
committerAAGaming <aagaming@riseup.net>2024-08-03 18:16:51 -0400
commitb3a5f9659f5744327103e28d1f9f53f393f23b6d (patch)
treefe3b82cacaaf808252957c3e7faf8e868dcf8d25
parentd444248f62c51a261c3a2b0f8ba097d9c0ef391b (diff)
downloaddecky-loader-aa/new-hooks.tar.gz
decky-loader-aa/new-hooks.zip
fix router hook on stableaa/new-hooks
-rw-r--r--frontend/src/router-hook.tsx10
1 files changed, 7 insertions, 3 deletions
diff --git a/frontend/src/router-hook.tsx b/frontend/src/router-hook.tsx
index cc00643a..8cffb738 100644
--- a/frontend/src/router-hook.tsx
+++ b/frontend/src/router-hook.tsx
@@ -62,9 +62,13 @@ class RouterHook extends Logger {
const reactRouterStackModule = findModuleByExport((e) => e == 'router-backstack', 20);
if (reactRouterStackModule) {
- this.Route = Object.values(reactRouterStackModule).find(
- (e) => typeof e == 'function' && /routePath:.\.match\?\.path./.test(e.toString()),
- );
+ this.Route =
+ Object.values(reactRouterStackModule).find(
+ (e) => typeof e == 'function' && /routePath:.\.match\?\.path./.test(e.toString()),
+ ) ||
+ Object.values(reactRouterStackModule).find(
+ (e) => typeof e == 'function' && /routePath:null===\(.=.\.match\)/.test(e.toString()),
+ );
if (!this.Route) {
this.error('Failed to find Route component');
}