diff --git a/src/renderer/patches/hideSwitchDevice.tsx b/src/renderer/patches/hideSwitchDevice.tsx index 5c87d28..f3acce2 100644 --- a/src/renderer/patches/hideSwitchDevice.tsx +++ b/src/renderer/patches/hideSwitchDevice.tsx @@ -18,6 +18,6 @@ addPatch({ ], shouldIgnore(state: any) { - return Object.keys(state?.default?.lastDeviceConnected)?.[0] === "vencord-screen-share"; + return Object.keys(state?.default?.lastDeviceConnected ?? {})?.[0] === "vencord-screen-share"; } });