Commit 0e3a2e6f by Ralph Broenink

Modify mixins.py to make sure that the 415 (Unsupported Media Type) returns its…

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).
parent 1f9a8e10
...@@ -181,7 +181,7 @@ class RequestMixin(object): ...@@ -181,7 +181,7 @@ class RequestMixin(object):
return parser.parse(stream) return parser.parse(stream)
raise ErrorResponse(status.HTTP_415_UNSUPPORTED_MEDIA_TYPE, raise ErrorResponse(status.HTTP_415_UNSUPPORTED_MEDIA_TYPE,
{'error': 'Unsupported media type in request \'%s\'.' % {'detail': 'Unsupported media type in request \'%s\'.' %
content_type}) content_type})
@property @property
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment