aboutsummaryrefslogtreecommitdiffstats
path: root/djangorestframework/renderers.py
diff options
context:
space:
mode:
authorTom Christie2011-06-21 23:01:41 +0100
committerTom Christie2011-06-21 23:01:41 +0100
commit82de0cf50a6f4ac2a3646a2524d149b7e7c85b2c (patch)
tree89e4cadadc02f2a87fff4c21dbdfc48039467770 /djangorestframework/renderers.py
parentf02a4e189063cbe67c3e452e06542f0856863f41 (diff)
downloaddjango-rest-framework-82de0cf50a6f4ac2a3646a2524d149b7e7c85b2c.tar.bz2
Decimals are a protected_type - let's leave them up to the renderer to deal with
Diffstat (limited to 'djangorestframework/renderers.py')
-rw-r--r--djangorestframework/renderers.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/djangorestframework/renderers.py b/djangorestframework/renderers.py
index 7aa8777c..56939bbc 100644
--- a/djangorestframework/renderers.py
+++ b/djangorestframework/renderers.py
@@ -108,6 +108,7 @@ class XMLRenderer(BaseRenderer):
"""
Renderer which serializes to XML.
"""
+
media_type = 'application/xml'
def render(self, obj=None, media_type=None):
@@ -251,6 +252,7 @@ class DocumentingTemplateRenderer(BaseRenderer):
The context used in the template contains all the information
needed to self-document the response to this request.
"""
+
content = self._get_content(self.view, self.view.request, obj, media_type)
put_form_instance = self._get_form_instance(self.view, 'put')