transmit multiple occurence of an argument into a list

This commit is contained in:
Jean-Marie Place 2021-09-21 06:48:54 +02:00
parent f18a9c7559
commit 9dd8198c7b

View File

@ -74,7 +74,8 @@ class ZRequest(object):
if k.endswith(":list"):
self.form[k[:-5]] = request.args.getlist(k)
else:
self.form[k] = request.args[k]
values = request.args.getlist(k)
self.form[k] = values[0] if len(values) == 1 else values
# current_app.logger.info("ZRequest.form=%s" % str(self.form))
self.RESPONSE = ZResponse()