mirror of
https://github.com/resf/distro-tools.git
synced 2024-12-10 21:46:26 +00:00
Properly account for repo categorization in updateinfo
This commit is contained in:
parent
9b60921a42
commit
c72684f08c
@ -194,6 +194,8 @@ async def get_updateinfo(
|
||||
# collections, and module RPMs need to go into their own collection based on
|
||||
# module name, while non-module RPMs go into the main collection (if any)
|
||||
for pkg in advisory.packages:
|
||||
if pkg.repo_name != repo:
|
||||
continue
|
||||
if pkg.module_name:
|
||||
collection_short = f"{default_collection_short}__{pkg.module_name}"
|
||||
if collection_short not in collections:
|
||||
@ -209,11 +211,11 @@ async def get_updateinfo(
|
||||
else:
|
||||
if no_default_collection:
|
||||
continue
|
||||
if collection_short not in collections:
|
||||
collections[collection_short] = {
|
||||
if default_collection_short not in collections:
|
||||
collections[default_collection_short] = {
|
||||
"packages": [],
|
||||
}
|
||||
collections[collection_short]["packages"].append(pkg)
|
||||
collections[default_collection_short]["packages"].append(pkg)
|
||||
|
||||
if no_default_collection and default_collection_short in collections:
|
||||
del collections[default_collection_short]
|
||||
|
Loading…
Reference in New Issue
Block a user