[Python-checkins] r88976 - tracker/roundup-src/roundup/cgi/client.py
martin.v.loewis
python-checkins at python.org
Fri Jun 15 09:15:17 CEST 2012
Author: martin.v.loewis
Date: Fri Jun 15 09:15:17 2012
New Revision: 88976
Log:
Fake a list property to prevent "Error: not indexable".
Modified:
tracker/roundup-src/roundup/cgi/client.py
Modified: tracker/roundup-src/roundup/cgi/client.py
==============================================================================
--- tracker/roundup-src/roundup/cgi/client.py (original)
+++ tracker/roundup-src/roundup/cgi/client.py Fri Jun 15 09:15:17 2012
@@ -305,6 +305,10 @@
# see if we need to re-parse the environment for the form (eg Zope)
if form is None:
self.form = cgi.FieldStorage(fp=request.rfile, environ=env)
+ # In some case (e.g. content-type application/xml), cgi
+ # will not parse anything. Fake a list property in this case
+ if self.form.list is None:
+ self.form.list = []
else:
self.form = form
More information about the Python-checkins
mailing list