diff --git a/dashmachine/sources.py b/dashmachine/sources.py index 1578772..6055ccd 100644 --- a/dashmachine/sources.py +++ b/dashmachine/sources.py @@ -83,11 +83,13 @@ def context_processor(): app_db.groups = None if check_groups(app_db.groups, current_user): apps.append(app_db) - tags += app_db.tags.split(",") + if app_db.tags: + tags += app_db.tags.split(",") tags_form = TagsForm() - tags = [tag.strip() for tag in tags] - tags = list(dict.fromkeys(tags)) + if len(tags) > 0: + tags = [tag.strip() for tag in tags] + tags = list(dict.fromkeys(tags)) tags_form.tags.choices += [(tag, tag) for tag in tags] settings = Settings.query.first() if settings.background == "random":