Ver Fonte

fix(upgrader): correct old executable path handling for non-Windows systems in core upgrade process

Jacky há 4 dias atrás
pai
commit
73553539ef
1 ficheiros alterados com 1 adições e 1 exclusões
  1. 1 1
      internal/upgrader/upgrade.go

+ 1 - 1
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))
 	}