From 3d70a0534b5b1e7a280603fdf5142b42b2542226 Mon Sep 17 00:00:00 2001 From: contributor Date: Sat, 8 Nov 2025 10:40:08 +0200 Subject: [PATCH] ignore toggle tray command if tray is disabled --- apps/client/src/components/root_command_executor.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/client/src/components/root_command_executor.ts b/apps/client/src/components/root_command_executor.ts index 632eb0a88..3ad05b7a2 100644 --- a/apps/client/src/components/root_command_executor.ts +++ b/apps/client/src/components/root_command_executor.ts @@ -171,7 +171,8 @@ export default class RootCommandExecutor extends Component { } toggleTrayCommand() { - if (!utils.isElectron()) return; + if (!utils.isElectron() || options.is("disableTray")) return; + const { BrowserWindow } = utils.dynamicRequire("@electron/remote"); const windows = BrowserWindow.getAllWindows() as Electron.BaseWindow[]; const isVisible = windows.every((w) => w.isVisible());