1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Merge pull request #3751 from hSaria/3749-attribute-error

Fixes 3749 attribute error
This commit is contained in:
Jeremy Stretch
2019-12-11 08:50:09 -05:00
committed by GitHub
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,9 @@
# v2.6.9 (FUTURE)
## Bug Fixes
* [#3749](https://github.com/netbox-community/netbox/issues/3749) - Fix exception on password change page for local users
# v2.6.8 (2019-12-10)
## Enhancements

View File

@ -96,7 +96,7 @@ class ChangePasswordView(LoginRequiredMixin, View):
def get(self, request):
# LDAP users cannot change their password here
if getattr(request.user, 'ldap_username'):
if getattr(request.user, 'ldap_username', None):
messages.warning(request, "LDAP-authenticated user credentials cannot be changed within NetBox.")
return redirect('user:profile')