Skip to content

Commit

Permalink
update settings migration logic to prevent overrdides (fix #1597)
Browse files Browse the repository at this point in the history
  • Loading branch information
marticliment committed Nov 30, 2023
1 parent b88b0de commit 111ca67
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions wingetui/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,17 +131,18 @@ def CheckProgramIntegrity():
legacy_ignored_updates_version = GetIgnoredPackageUpdates_SpecificVersion()

try:
for pkglist in legacy_ignored_updates:
if len(pkglist) == 2:
package = Package(pkglist[0], pkglist[0], "", pkglist[1], None)
package.AddToIgnoredUpdates()
setSettings("PermanentlyIgnoredPackageUpdates", False)

for pkglist in legacy_ignored_updates_version:
if len(pkglist) == 3:
package = Package(pkglist[0], pkglist[0], pkglist[1], pkglist[2], None)
package.AddToIgnoredUpdates(package.Version)
setSettings("SingleVersionIgnoredPackageUpdates", False)

for pkglist in legacy_ignored_updates:
if len(pkglist) == 2:
package = Package(pkglist[0], pkglist[0], "", pkglist[1], None)
package.AddToIgnoredUpdates()
setSettings("PermanentlyIgnoredPackageUpdates", False)

except Exception as e:
report(e)
Expand Down

0 comments on commit 111ca67

Please sign in to comment.