[Zope3-checkins] CVS: Zope3/src/zope/app/rdb - __init__.py:1.17
Sidnei da Silva
sidnei@x3ng.com.br
Fri, 4 Jul 2003 09:01:30 -0400
Update of /cvs-repository/Zope3/src/zope/app/rdb
In directory cvs.zope.org:/tmp/cvs-serv32185
Modified Files:
__init__.py
Log Message:
Reverting previous checkin at SteveA's request. I need to figure out if it was a flaw of the mysqldb module or the test isnt testing what it was supposed to test.
=== Zope3/src/zope/app/rdb/__init__.py 1.16 => 1.17 ===
--- Zope3/src/zope/app/rdb/__init__.py:1.16 Thu Jul 3 18:46:12 2003
+++ Zope3/src/zope/app/rdb/__init__.py Fri Jul 4 09:01:26 2003
@@ -272,21 +272,11 @@
## if [x for x in converters if x is not ZopeDatabaseAdapter.identity]:
## return results # optimize away
-## XXX Geez! This was badly broken for me, and srichter was not
-## around to explain what this code is supposed to do when
-## theres only one row/one column on the result.
-
def convertRow(row):
- try:
- return map(lambda converter, value: converter(value),
- converters, row)
- except TypeError:
- return converters[0](row)
+ return map(lambda converter, value: converter(value),
+ converters, row)
- try:
- return map(convertRow, results)
- except TypeError:
- return convertRow(results)
+ return map(convertRow, results)
class ZopeConnection: