diff options
| author | Tom Christie | 2013-12-09 07:45:45 +0000 |
|---|---|---|
| committer | Tom Christie | 2013-12-09 07:45:45 +0000 |
| commit | 80ef2685e522fc87bd8af9767aa7b231c9991ea4 (patch) | |
| tree | 4be3191af2eec42ffea97443c9e9f11ee5631ca7 /rest_framework/response.py | |
| parent | 4e9385e709bcee87456a99839841ecf6b56f337a (diff) | |
| parent | 175b4d233d578b5964db72f91a96bb3b4a0f3e99 (diff) | |
| download | django-rest-framework-80ef2685e522fc87bd8af9767aa7b231c9991ea4.tar.bz2 | |
Merge master
Diffstat (limited to 'rest_framework/response.py')
| -rw-r--r-- | rest_framework/response.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/rest_framework/response.py b/rest_framework/response.py index 5877c8a3..1dc6abcf 100644 --- a/rest_framework/response.py +++ b/rest_framework/response.py @@ -61,6 +61,10 @@ class Response(SimpleTemplateResponse): assert charset, 'renderer returned unicode, and did not specify ' \ 'a charset value.' return bytes(ret.encode(charset)) + + if not ret: + del self['Content-Type'] + return ret @property |
