From 73553539ef9ba9e1a643f8db6aca07935245f97d Mon Sep 17 00:00:00 2001 From: Jacky Date: Tue, 6 May 2025 22:58:24 +0800 Subject: [PATCH] fix(upgrader): correct old executable path handling for non-Windows systems in core upgrade process --- internal/upgrader/upgrade.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/upgrader/upgrade.go b/internal/upgrader/upgrade.go index 9f08af19..3e1b99cf 100644 --- a/internal/upgrader/upgrade.go +++ b/internal/upgrader/upgrade.go @@ -219,7 +219,7 @@ func (u *Upgrader) PerformCoreUpgrade(tarPath string) (err error) { defer updateInProgress.Store(false) oldExe := "" - if runtime.GOOS != "windows" { + if runtime.GOOS == "windows" { oldExe = filepath.Join(filepath.Dir(u.ExPath), ".nginx-ui.old."+strconv.FormatInt(time.Now().Unix(), 10)) }