mirror of
https://github.com/safing/portmaster
synced 2025-09-01 18:19:12 +00:00
Merge pull request #53 from safing/fix/file-move-upgrading
Remove version information from moved file
This commit is contained in:
commit
6c029d0ce3
1 changed files with 1 additions and 2 deletions
|
@ -175,7 +175,6 @@ func upgradeFile(fileToUpgrade string, file *updater.File) error {
|
|||
// test currentVersion for sanity
|
||||
if !rawVersionRegex.MatchString(currentVersion) {
|
||||
log.Tracef("updates: version string returned by %s is invalid: %s", fileToUpgrade, currentVersion)
|
||||
currentVersion = "0.0.0"
|
||||
}
|
||||
|
||||
// try removing old version
|
||||
|
@ -192,7 +191,7 @@ func upgradeFile(fileToUpgrade string, file *updater.File) error {
|
|||
registry.TmpDir().Path,
|
||||
fmt.Sprintf(
|
||||
"%s-%d%s",
|
||||
updater.GetVersionedPath(filepath.Base(fileToUpgrade), currentVersion),
|
||||
filepath.Base(fileToUpgrade),
|
||||
time.Now().UTC().Unix(),
|
||||
upgradedSuffix,
|
||||
),
|
||||
|
|
Loading…
Add table
Reference in a new issue