refactor(ipc): remove Windows ARM update check from IPC handler and AboutSettings component
This commit is contained in:
parent
f372ebe485
commit
d1c2bbed1b
@ -154,14 +154,6 @@ export function registerIpc(mainWindow: BrowserWindow, app: Electron.App) {
|
||||
|
||||
// check for update
|
||||
ipcMain.handle(IpcChannel.App_CheckForUpdate, async () => {
|
||||
// 在 Windows 上,如果架构是 arm64,则不检查更新
|
||||
if (isWin && arch().includes('arm')) {
|
||||
return {
|
||||
currentVersion: app.getVersion(),
|
||||
updateInfo: null
|
||||
}
|
||||
}
|
||||
|
||||
const update = await appUpdater.autoUpdater.checkForUpdates()
|
||||
|
||||
return {
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
import { GithubOutlined } from '@ant-design/icons'
|
||||
import IndicatorLight from '@renderer/components/IndicatorLight'
|
||||
import { HStack } from '@renderer/components/Layout'
|
||||
import { isWindows } from '@renderer/config/constant'
|
||||
import { APP_NAME, AppLogo } from '@renderer/config/env'
|
||||
import { useTheme } from '@renderer/context/ThemeProvider'
|
||||
import { useMinappPopup } from '@renderer/hooks/useMinappPopup'
|
||||
@ -34,13 +33,6 @@ const AboutSettings: FC = () => {
|
||||
|
||||
const onCheckUpdate = debounce(
|
||||
async () => {
|
||||
const { arch } = await window.api.getAppInfo()
|
||||
|
||||
if (isWindows && arch.includes('arm')) {
|
||||
window.open('https://cherry-ai.com/download', '_blank')
|
||||
return
|
||||
}
|
||||
|
||||
if (update.checking || update.downloading) {
|
||||
return
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user