aboutsummaryrefslogtreecommitdiffstats
path: root/djangorestframework/mixins.py
diff options
context:
space:
mode:
authorRalph Broenink2012-07-06 15:43:02 +0300
committerRalph Broenink2012-07-06 15:43:02 +0300
commit0e3a2e6fdd800465b07817d780a981a18cb79880 (patch)
tree5b115c642c880548bc1639fae505e24ea54b6553 /djangorestframework/mixins.py
parent1f9a8e10e5535cd301f5aca8de7fcea7e5310091 (diff)
downloaddjango-rest-framework-0e3a2e6fdd800465b07817d780a981a18cb79880.tar.bz2
Modify mixins.py to make sure that the 415 (Unsupported Media Type) returns its error in the 'detail' key instead of in the 'error' key (for consistency with all other errors).
Diffstat (limited to 'djangorestframework/mixins.py')
-rw-r--r--djangorestframework/mixins.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/djangorestframework/mixins.py b/djangorestframework/mixins.py
index 0f292b4e..4a453957 100644
--- a/djangorestframework/mixins.py
+++ b/djangorestframework/mixins.py
@@ -181,7 +181,7 @@ class RequestMixin(object):
return parser.parse(stream)
raise ErrorResponse(status.HTTP_415_UNSUPPORTED_MEDIA_TYPE,
- {'error': 'Unsupported media type in request \'%s\'.' %
+ {'detail': 'Unsupported media type in request \'%s\'.' %
content_type})
@property