fixed env['QUERY_STRING'], thanks Anthony
This commit is contained in:
1 parent
93b9b4dfbe
commit
7936ab8ef9
2 files changed
+4
-1
No files matched your search
@@ -1 +1 @@
|
|||||||
Version 2.6.0-development+timestamp.2013.08.21.17.26.48
|
Version 2.6.0-development+timestamp.2013.08.22.02.18.31
|
||||||
@@ -196,8 +196,11 @@ class Request(Storage):
|
|||||||
if (body and
|
if (body and
|
||||||
env.request_method in ('POST', 'PUT', 'DELETE', 'BOTH') and
|
env.request_method in ('POST', 'PUT', 'DELETE', 'BOTH') and
|
||||||
not is_json):
|
not is_json):
|
||||||
|
query_string = env.pop('QUERY_STRING') if 'QUERY_STRING' in env else None
|
||||||
dpost = cgi.FieldStorage(fp=body, environ=env, keep_blank_values=1)
|
dpost = cgi.FieldStorage(fp=body, environ=env, keep_blank_values=1)
|
||||||
post_vars.update(dpost)
|
post_vars.update(dpost)
|
||||||
|
if query_string is not None:
|
||||||
|
env['QUERY_STRING'] = query_string
|
||||||
# The same detection used by FieldStorage to detect multipart POSTs
|
# The same detection used by FieldStorage to detect multipart POSTs
|
||||||
is_multipart = dpost.type[:10] == 'multipart/'
|
is_multipart = dpost.type[:10] == 'multipart/'
|
||||||
body.seek(0)
|
body.seek(0)
|
||||||
|
|||||||
Reference in new issue
Block a user