[Zope-Checkins] CVS: Zope/lib/python/Products/PluginIndexes/TextIndex - TextIndex.py:1.20

Andreas Jung andreas@zope.com
Fri, 12 Oct 2001 09:17:49 -0400


Update of /cvs-repository/Zope/lib/python/Products/PluginIndexes/TextIndex
In directory cvs.zope.org:/tmp/cvs-serv19120

Modified Files:
	TextIndex.py 
Log Message:
been using isinstance() on wrong type instead of instance


=== Zope/lib/python/Products/PluginIndexes/TextIndex/TextIndex.py 1.19 => 1.20 ===
         if operandType is IntType:
             left = self[left]
-        elif isinstance(operandType,StringType) or \
-             isinstance(operandType,UnicodeType):
+        elif operandType in (StringType,UnicodeType): 
             left = self[left]        
         elif operandType is ListType:
             left = self.evaluate(left)
@@ -640,8 +639,7 @@
         operandType = type(right)
         if operandType is IntType:
             right = self[right]
-        elif isinstance(operandType,StringType) or \
-             isinstance(operandType,UnicodeType):
+        elif operandType in (StringType,UnicodeType): 
             right = self[right]       
         elif operandType is ListType:
             right = self.evaluate(right)