summaryrefslogtreecommitdiff
path: root/frontend/src/toaster.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/src/toaster.tsx')
-rw-r--r--frontend/src/toaster.tsx5
1 files changed, 3 insertions, 2 deletions
diff --git a/frontend/src/toaster.tsx b/frontend/src/toaster.tsx
index e5b2d986..572a1bba 100644
--- a/frontend/src/toaster.tsx
+++ b/frontend/src/toaster.tsx
@@ -4,7 +4,7 @@ import {
ErrorBoundary,
Patch,
callOriginal,
- findModuleExport,
+ findVar,
injectFCTrampoline,
replacePatch,
} from '@decky/ui';
@@ -27,7 +27,8 @@ class Toaster extends Logger {
window.__TOASTER_INSTANCE?.deinit?.();
window.__TOASTER_INSTANCE = this;
- const ValveToastRenderer = findModuleExport((e) => e?.toString?.()?.includes(`controller:"notification",method:`));
+ // TODO regex?
+ const ValveToastRenderer = findVar((e) => e?.toString?.()?.includes(`controller:\`notification\`,method:`));
// TODO find a way to undo this if possible?
const patchedRenderer = injectFCTrampoline(ValveToastRenderer);
this.toastPatch = replacePatch(patchedRenderer, 'component', (args: any[]) => {