forked from ScoDoc/ScoDoc
Fix scodoc7 http non GET/POST requests
This commit is contained in:
parent
963c09976b
commit
1167c13787
@ -1138,10 +1138,11 @@ def send_docx(document, filename):
|
||||
)
|
||||
|
||||
|
||||
def get_request_args():
|
||||
def get_request_args() -> dict:
|
||||
"""returns a dict with request (POST or GET) arguments
|
||||
converted to suit legacy Zope style (scodoc7) functions.
|
||||
"""
|
||||
vals = {}
|
||||
# copy to get a mutable object (necessary for TrivialFormulator and several methods)
|
||||
if request.method == "POST":
|
||||
# request.form is a werkzeug.datastructures.ImmutableMultiDict
|
||||
@ -1154,7 +1155,6 @@ def get_request_args():
|
||||
if k.endswith(":list"):
|
||||
vals[k[:-5]] = request.form.getlist(k)
|
||||
elif request.method == "GET":
|
||||
vals = {}
|
||||
for k in request.args:
|
||||
# current_app.logger.debug("%s\t%s" % (k, request.args.getlist(k)))
|
||||
if k.endswith(":list"):
|
||||
|
@ -1,7 +1,7 @@
|
||||
# -*- mode: python -*-
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
SCOVERSION = "9.6.970"
|
||||
SCOVERSION = "9.6.971"
|
||||
|
||||
SCONAME = "ScoDoc"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user