mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-18 05:29:38 -04:00
remove any_ from has_permissions
we branch on any_ to either say "require ALL these permissions" or "require ANY of these permissions". But we only ever call the decorator with one permission, or with any_=True, so it's unnecessary
This commit is contained in:
@@ -107,7 +107,7 @@
|
||||
|
||||
{% macro edit_field(text, link, permissions=[]) -%}
|
||||
{% call field(align='right') %}
|
||||
{% if current_user.has_permissions(*permissions, **{'any_': True}) or not permissions %}
|
||||
{% if current_user.has_permissions(*permissions) or not permissions %}
|
||||
<a href="{{ link }}">{{ text }}</a>
|
||||
{% endif %}
|
||||
{% endcall %}
|
||||
|
||||
Reference in New Issue
Block a user