mirror of
https://github.com/Vencord/Vesktop.git
synced 2026-11-28 04:46:23 -08:00
fix(autoStart): persist Start With System toggle on Windows (#1277)
Co-authored-by: Claude Opus 4.8 <[email protected]>
This commit is contained in:
1 parent
f96f325594
commit
198dfedd5f
1 file changed
+5
-1
@@ -73,7 +73,11 @@ function makeAutoStartLinuxPortal() {
|
||||
}
|
||||
|
||||
const autoStartWindowsMac: AutoStart = {
|
||||
isEnabled: () => app.getLoginItemSettings().openAtLogin,
|
||||
isEnabled: () => {
|
||||
const { openAtLogin, executableWillLaunchAtLogin } = app.getLoginItemSettings();
|
||||
// Windows only reports openAtLogin as true when queried with the same args set in enable()
|
||||
return openAtLogin || executableWillLaunchAtLogin;
|
||||
},
|
||||
enable: () =>
|
||||
app.setLoginItemSettings({
|
||||
openAtLogin: true,
|
||||
|
||||
Reference in new issue
Block a user