fix: show unflag link to flagger

While the flagger is allowed to unflag a package, the link to do so is
hidden from them. Fix by adding the flagger to the unflag list.

Fix #380
This commit is contained in:
Leon Möller 2022-08-12 18:43:18 +02:00 committed by Leon Möller
parent 15d016eb70
commit 33bf5df236

View file

@ -46,7 +46,7 @@ def make_context(request: Request, pkgbase: PackageBase,
).all() ).all()
] ]
context["unflaggers"] = context["comaintainers"].copy() context["unflaggers"] = context["comaintainers"].copy()
context["unflaggers"].append(pkgbase.Maintainer) context["unflaggers"].extend([pkgbase.Maintainer, pkgbase.Flagger])
context["packages_count"] = pkgbase.packages.count() context["packages_count"] = pkgbase.packages.count()
context["keywords"] = pkgbase.keywords context["keywords"] = pkgbase.keywords