mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-16 20:20:29 +03:00
update: If cateogories.yml only has icon:, then add name:
E.g. if _categories.yml_ is like: ```yaml Time: icon: time.png ```
This commit is contained in:
parent
964861eb68
commit
494d811846
2 changed files with 38 additions and 1 deletions
|
|
@ -775,7 +775,9 @@ def make_v2(apps, packages, repodir, repodict, requestsdict, signer_fingerprints
|
|||
# include definitions for "auto-defined" categories, e.g. just used in app metadata
|
||||
for category in sorted(categories_used_by_apps):
|
||||
if category not in output['repo'][CATEGORIES_CONFIG_NAME]:
|
||||
output['repo'][CATEGORIES_CONFIG_NAME][category] = {"name": {DEFAULT_LOCALE: category}}
|
||||
output['repo'][CATEGORIES_CONFIG_NAME][category] = dict()
|
||||
if 'name' not in output['repo'][CATEGORIES_CONFIG_NAME][category]:
|
||||
output['repo'][CATEGORIES_CONFIG_NAME][category]['name'] = {DEFAULT_LOCALE: category}
|
||||
# do not include defined categories if no apps use them
|
||||
for category in list(output['repo'].get(CATEGORIES_CONFIG_NAME, list())):
|
||||
if category not in categories_used_by_apps:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue