mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-06-19 05:40:01 +10:00
products.py: Verify item exists before removal
This commit is contained in:
@@ -238,7 +238,8 @@ class CatalogProducts:
|
|||||||
if installer["Catalog"] in [SeedType.CustomerSeed, SeedType.DeveloperSeed, SeedType.PublicSeed]:
|
if installer["Catalog"] in [SeedType.CustomerSeed, SeedType.DeveloperSeed, SeedType.PublicSeed]:
|
||||||
for installer_2 in products:
|
for installer_2 in products:
|
||||||
if installer_2["Version"].split(".")[0] == installer["Version"].split(".")[0] and installer_2["Catalog"] not in [SeedType.CustomerSeed, SeedType.DeveloperSeed, SeedType.PublicSeed]:
|
if installer_2["Version"].split(".")[0] == installer["Version"].split(".")[0] and installer_2["Catalog"] not in [SeedType.CustomerSeed, SeedType.DeveloperSeed, SeedType.PublicSeed]:
|
||||||
products.remove(installer)
|
if installer in products:
|
||||||
|
products.remove(installer)
|
||||||
|
|
||||||
# Remove EOL versions (older than n-3)
|
# Remove EOL versions (older than n-3)
|
||||||
for installer in products:
|
for installer in products:
|
||||||
|
|||||||
Reference in New Issue
Block a user