From 90b8c5fdfed91044d18ea951109e54a6873896d6 Mon Sep 17 00:00:00 2001 From: Vendicated Date: Mon, 10 Apr 2023 19:18:00 +0200 Subject: [PATCH] lint --- src/main/mainWindow.ts | 6 ++---- src/renderer/components/Settings.tsx | 9 ++------- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/src/main/mainWindow.ts b/src/main/mainWindow.ts index 93458df..c0971ad 100644 --- a/src/main/mainWindow.ts +++ b/src/main/mainWindow.ts @@ -215,10 +215,8 @@ function initWindowBoundsListeners(win: BrowserWindow) { function initSettingsListeners(win: BrowserWindow) { Settings.addChangeListener("tray", enable => { - if (enable) - initTray(win); - else - tray?.destroy(); + if (enable) initTray(win); + else tray?.destroy(); }); Settings.addChangeListener("disableMinSize", disable => { if (disable) { diff --git a/src/renderer/components/Settings.tsx b/src/renderer/components/Settings.tsx index 995100a..6e5760e 100644 --- a/src/renderer/components/Settings.tsx +++ b/src/renderer/components/Settings.tsx @@ -22,18 +22,13 @@ export default function SettingsUi() { } = Common; const switches: [keyof typeof Settings, string, string, boolean?, (() => boolean)?][] = [ - [ - "tray", - "Tray Icon", - "Add a tray icon for Vencord Desktop", - true - ], + ["tray", "Tray Icon", "Add a tray icon for Vencord Desktop", true], [ "minimizeToTray", "Minimize to tray", "Hitting X will make Vencord Desktop minimize to the tray instead of closing", true, - () => Settings["tray"] ?? true + () => Settings.tray ?? true ], [ "disableMinSize",