Skip to content

Commit

Permalink
Replaced lookup of non-existent attr in user model
Browse files Browse the repository at this point in the history
  • Loading branch information
acoollevel committed Jan 29, 2020
1 parent 8eb2f35 commit f39ecf9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions error_tracker/django/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ def notify(self, request, exception,
class DefaultDjangoViewPermission(ViewPermissionMixin):

def __call__(self, request):
if hasattr(request.user, "is_admin"):
return request.user.is_admin()
if hasattr(request.user, "is_superuser"):
return request.user.is_superuser
return False


Expand Down

0 comments on commit f39ecf9

Please sign in to comment.