1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Fixed #20961 -- Fixed HttpResponse default empty content

Thanks epandurski at gmail.com for the report.
This commit is contained in:
Claude Paroz
2013-08-24 18:08:05 +02:00
parent f33db5a09a
commit f4e9804567
2 changed files with 8 additions and 1 deletions

View File

@@ -317,7 +317,7 @@ class HttpResponse(HttpResponseBase):
streaming = False
def __init__(self, content='', *args, **kwargs):
def __init__(self, content=b'', *args, **kwargs):
super(HttpResponse, self).__init__(*args, **kwargs)
# Content is a bytestring. See the `content` property methods.
self.content = content