Skip to content

Commit

Permalink
Fix a couple cases
Browse files Browse the repository at this point in the history
  • Loading branch information
davisagli committed Oct 2, 2018
1 parent a3457e0 commit 078c338
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/ZPublisher/HTTPRequest.py
Expand Up @@ -505,14 +505,11 @@ def processInputs(
if 'CONTENT_LENGTH' in environ and environ['CONTENT_LENGTH'] != '0':
# In order to override content-disposition we need to
# specify the full headers; this is based on FileStorage.__init__
headers = {}
if method == 'POST':
# Set default content-type for POST to what's traditional
headers['content-type'] = "application/x-www-form-urlencoded"
headers = {
'content-type': 'application/x-www-form-urlencoded'
}
if 'CONTENT_TYPE' in environ:
headers['content-type'] = environ['CONTENT_TYPE']
if 'QUERY_STRING' in environ:
self.qs_on_post = environ['QUERY_STRING']
headers['content-length'] = environ['CONTENT_LENGTH']
headers['content-disposition'] = 'inline; filename="stdin"'
fs = FieldStorage(
Expand Down

0 comments on commit 078c338

Please sign in to comment.