Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed #17967: Hide "Change Password" link in admin if user.has_usable…

…_password is False.
  • Loading branch information...
commit 9bea85795705d015cdadc82c68b99196a8554f5c 1 parent 97c8992
@aviraldg aviraldg authored
Showing with 2 additions and 0 deletions.
  1. +2 −0  django/contrib/admin/templates/admin/base.html
View
2  django/contrib/admin/templates/admin/base.html
@@ -32,7 +32,9 @@
{% if docsroot %}
<a href="{{ docsroot }}">{% trans 'Documentation' %}</a> /
{% endif %}
+ {% if user.has_usable_password %}
<a href="{% url 'admin:password_change' %}">{% trans 'Change password' %}</a> /
+ {% endif $}
<a href="{% url 'admin:logout' %}">{% trans 'Log out' %}</a>
{% endblock %}
</div>
Please sign in to comment.
Something went wrong with that request. Please try again.