aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework/permissions.py
diff options
context:
space:
mode:
authorTom Christie2013-03-12 20:12:28 +0000
committerTom Christie2013-03-12 20:12:28 +0000
commit043d748b539a6f5b4cfdf6de650b072541f1c6da (patch)
treeb141104f7ac66704ba41fb8d746450f3569aa50b /rest_framework/permissions.py
parenta574dc7f85e09b4c0096d7b1c12a8e525ea8e31f (diff)
downloaddjango-rest-framework-043d748b539a6f5b4cfdf6de650b072541f1c6da.tar.bz2
Tweak
Diffstat (limited to 'rest_framework/permissions.py')
-rw-r--r--rest_framework/permissions.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/rest_framework/permissions.py b/rest_framework/permissions.py
index f026850a..ae895f39 100644
--- a/rest_framework/permissions.py
+++ b/rest_framework/permissions.py
@@ -153,7 +153,7 @@ class TokenHasReadWriteScope(BasePermission):
elif hasattr(token, 'scope'): # OAuth 2
required = oauth2_constants.READ if read_only else oauth2_constants.WRITE
return oauth2_provider_scope.check(required, request.auth.scope)
- else:
- assert False, ('TokenHasReadWriteScope requires either the'
- '`OAuthAuthentication` or `OAuth2Authentication` authentication '
- 'class to be used.')
+
+ assert False, ('TokenHasReadWriteScope requires either the'
+ '`OAuthAuthentication` or `OAuth2Authentication` authentication '
+ 'class to be used.')