mirror of
https://github.com/django/django.git
synced 2025-10-27 07:36:08 +00:00
[1.6.x] Fixed #20961 -- Fixed HttpResponse default empty content
Thanks epandurski at gmail.com for the report.
Backport of f4e980456 from master.
This commit is contained in:
@@ -323,7 +323,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
|
||||
|
||||
Reference in New Issue
Block a user