From 4814b88172980951e464be81938fa9c301362a79 Mon Sep 17 00:00:00 2001 From: josc146 Date: Tue, 6 Jun 2023 21:52:38 +0800 Subject: [PATCH] chore --- backend-golang/utils.go | 7 ++----- frontend/src/utils/index.tsx | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/backend-golang/utils.go b/backend-golang/utils.go index 1c8f2db..5cc76d5 100644 --- a/backend-golang/utils.go +++ b/backend-golang/utils.go @@ -17,11 +17,8 @@ import ( func Cmd(args ...string) (string, error) { switch platform := runtime.GOOS; platform { case "windows": - _, err := os.Stat("cmd-helper.bat") - if err != nil { - if err := os.WriteFile("./cmd-helper.bat", []byte("start %*"), 0644); err != nil { - return "", err - } + if err := os.WriteFile("./cmd-helper.bat", []byte("start /wait %*"), 0644); err != nil { + return "", err } cmdHelper, err := filepath.Abs("./cmd-helper") if err != nil { diff --git a/frontend/src/utils/index.tsx b/frontend/src/utils/index.tsx index f9b5f31..0a18ef3 100644 --- a/frontend/src/utils/index.tsx +++ b/frontend/src/utils/index.tsx @@ -248,7 +248,7 @@ export async function checkUpdate(notifyEvenLatest: boolean = false) { toast(t('Downloading update, please wait. If it is not completed, please manually download the program from GitHub and replace the original program.'), { type: 'info', position: 'bottom-left', - autoClose: 10000 + autoClose: 20000 }); setTimeout(() => { UpdateApp(updateUrl).catch((e) => {