mirror of
https://github.com/django/django.git
synced 2025-10-27 07:36:08 +00:00
Changed handlers (both mod_python and WSGI) to support setting multiple cookies per request
git-svn-id: http://code.djangoproject.com/svn/django/trunk@511 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -138,9 +138,9 @@ class WSGIHandler(BaseHandler):
|
||||
except KeyError:
|
||||
status_text = 'UNKNOWN STATUS CODE'
|
||||
status = '%s %s' % (response.status_code, status_text)
|
||||
response_headers = response.headers
|
||||
if response.cookies:
|
||||
response_headers['Set-Cookie'] = response.cookies.output(header='')
|
||||
response_headers = response.headers.items()
|
||||
for c in response.cookies.values():
|
||||
response_headers.append(('Set-Cookie', c.output(header='')))
|
||||
output = [response.get_content_as_string('utf-8')]
|
||||
start_response(status, response_headers.items())
|
||||
start_response(status, response_headers)
|
||||
return output
|
||||
|
||||
Reference in New Issue
Block a user