tomchristie/django-rest-framework — Issue #88: permissions.IsAdminUser is not valid
Author: Natim
Created: 2011-12-03 09:44:49+00:00
State: open

Here is the patch

diff -r 1a7ab7e5129c djangorestframework/permissions.py
--- a/djangorestframework/permissions.py	Wed Jul 13 12:42:02 2011 +0100
+++ b/djangorestframework/permissions.py	Sat Dec 03 10:43:13 2011 +0100
@@ -73,7 +73,7 @@
"""

def check_permission(self, user):
- if not user.is_admin():
+ if not user.is_superuser:
raise _403_FORBIDDEN_RESPONSE