Skip to content

Commit 3f94c8d

Browse files
committed
[UI/UX] Remove 'Check for Updates on Startup' setting
1 parent 15aae12 commit 3f94c8d

File tree

5 files changed

+3
-56
lines changed

5 files changed

+3
-56
lines changed

src/backend/config.ts

-1
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,6 @@ class GlobalConfigV0 extends GlobalConfig {
295295
autoInstallDxvkNvapi: false,
296296
addSteamShortcuts: false,
297297
preferSystemLibs: false,
298-
checkForUpdatesOnStartup: !isLinux,
299298
autoUpdateGames: true,
300299
customWinePaths: isWindows ? null : [],
301300
defaultInstallPath: installPath,

src/backend/updater/updater.ts

+3-13
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { app, dialog, shell } from 'electron'
22
import { autoUpdater } from 'electron-updater'
33
import { t } from 'i18next'
44

5-
import { configStore, icon, isLinux } from '../constants'
5+
import { icon, isLinux } from '../constants'
66
import { logError, logInfo, LogPrefix } from '../logger/logger'
77
import { captureException } from '@sentry/electron'
88
import { getFileSize } from '../utils'
@@ -12,11 +12,9 @@ import { getErrorMessage, removeCachedUpdatesFolder } from './utils'
1212
// to test auto update on windows locally make sure you added the option verifyUpdateCodeSignature: false
1313
// under build.win in electron-builder.yml and also change the app version to an old one there
1414

15-
const appSettings = configStore.get_nodefault('settings')
16-
const shouldCheckForUpdates = appSettings?.checkForUpdatesOnStartup === true
1715
let newVersion: string
1816

19-
autoUpdater.autoDownload = shouldCheckForUpdates && !isLinux
17+
autoUpdater.autoDownload = !isLinux
2018
autoUpdater.autoInstallOnAppQuit = true
2119

2220
let isAppUpdating = false
@@ -29,7 +27,7 @@ const MAX_UPDATE_ATTEMPTS = 10
2927
const checkUpdateInterval = 3 * 1000 * 60 * 60
3028

3129
setInterval(async () => {
32-
if (shouldCheckForUpdates && !hasUpdated && !isAppUpdating) {
30+
if (!hasUpdated && !isAppUpdating) {
3331
logInfo('Checking for client updates...', LogPrefix.AutoUpdater)
3432
await autoUpdater.checkForUpdates()
3533
}
@@ -44,14 +42,6 @@ autoUpdater.on('update-available', async (info) => {
4442
return
4543
}
4644

47-
if (!shouldCheckForUpdates) {
48-
logInfo(
49-
'New update available, but user has disabled auto updates',
50-
LogPrefix.AutoUpdater
51-
)
52-
53-
return
54-
}
5545
newVersion = info.version
5646

5747
trackEvent({

src/frontend/screens/Settings/components/CheckUpdatesOnStartup.tsx

-38
This file was deleted.

src/frontend/screens/Settings/components/index.ts

-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ export { default as AutoDXVKNVAPI } from './AutoDXVKNVAPI'
44
export { default as AutoUpdateGames } from './AutoUpdateGames'
55
export { default as AutoVKD3D } from './AutoVKD3D'
66
export { default as BattlEyeRuntime } from './BattlEyeRuntime'
7-
export { default as CheckUpdatesOnStartup } from './CheckUpdatesOnStartup'
87
export { default as CrossoverBottle } from './CrossoverBottle'
98
export { default as CustomWineProton } from './CustomWineProton'
109
export { default as DefaultInstallPath } from './DefaultInstallPath'

src/frontend/screens/Settings/sections/GeneralSettings/index.tsx

-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { useTranslation } from 'react-i18next'
33
import LanguageSelector from 'frontend/components/UI/LanguageSelector'
44
import {
55
AutoUpdateGames,
6-
CheckUpdatesOnStartup,
76
DefaultInstallPath,
87
DefaultSteamPath,
98
EgsSettings,
@@ -40,8 +39,6 @@ export default function GeneralSettings() {
4039

4140
<AutoLaunchHyperPlay />
4241

43-
<CheckUpdatesOnStartup />
44-
4542
<AutoUpdateGames />
4643

4744
<TraySettings />

0 commit comments

Comments
 (0)