fix(FastAPI): reorganize credential checkin into dedicated file

Signed-off-by: Steven Guikal <void@fluix.one>
This commit is contained in:
Steven Guikal 2021-11-30 15:44:18 -05:00
parent 125b244f44
commit a10f8663fd
15 changed files with 143 additions and 172 deletions

View file

@ -21,7 +21,7 @@
</li>
{# Only CRED_ACCOUNT_SEARCH privileged users see Accounts #}
{% if request.user.has_credential("CRED_ACCOUNT_SEARCH") %}
{% if request.user.has_credential(creds.ACCOUNT_SEARCH) %}
<li>
<a href="/accounts">
{% trans %}Accounts{% endtrans %}
@ -37,7 +37,7 @@
</li>
{# Only CRED_TU_LIST_VOTES privileged users see Trusted User #}
{% if request.user.has_credential("CRED_TU_LIST_VOTES") %}
{% if request.user.has_credential(creds.TU_LIST_VOTES) %}
<li>
<a href="/tu">{% trans %}Trusted User{% endtrans %}</a>
</li>