mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-20 18:05:19 -04:00
fix navbar showing user info even when not logged in
This commit is contained in:
parent
68a506e1a7
commit
4b098bea15
1 changed files with 14 additions and 10 deletions
|
@ -9,6 +9,7 @@
|
||||||
<a href="{% url 'public-index' %}">Public</a> |
|
<a href="{% url 'public-index' %}">Public</a> |
|
||||||
<a href="/admin/">Admin</a>
|
<a href="/admin/">Admin</a>
|
||||||
|
|
||||||
|
{% if user.is_authenticated %}
|
||||||
{% block welcome-msg %}
|
{% block welcome-msg %}
|
||||||
{% trans 'User' %}
|
{% trans 'User' %}
|
||||||
<strong>{% firstof user.get_short_name user.get_username %}</strong>
|
<strong>{% firstof user.get_short_name user.get_username %}</strong>
|
||||||
|
@ -19,4 +20,7 @@
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<a href="{% url 'admin:logout' %}">{% trans 'Log out' %}</a>
|
<a href="{% url 'admin:logout' %}">{% trans 'Log out' %}</a>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
{% else %}
|
||||||
|
<a href="{% url 'admin:login' %}">{% trans 'Log in' %}</a>
|
||||||
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue