[Zope-Checkins] CVS: Zope2 - util.py:1.1.2.8
Andreas Jung
andreas@digicool.com
Wed, 23 May 2001 14:45:45 -0400
Update of /cvs-repository/Zope2/lib/python/Products/PluginIndexes/common
In directory yetix:/work/sandboxes/ajung-dropin-registry/lib/python/Products/PluginIndexes/common
Modified Files:
Tag: ajung-dropin-registry
util.py
Log Message:
added some checks for disgusting Catalog behaviour
--- Updated File util.py in package Zope2 --
--- util.py 2001/05/23 14:19:53 1.1.2.7
+++ util.py 2001/05/23 18:45:38 1.1.2.8
@@ -87,7 +87,7 @@
import re
-from types import StringType,ListType,TupleType,DictType
+from types import StringType,ListType,TupleType,DictType,InstanceType
class parseIndexRequest:
"""
@@ -136,6 +136,7 @@
self.id = iid
self.keys = None
+
if not request.has_key(iid): return
if request.has_key(iid+'_usage'):
@@ -198,6 +199,11 @@
for p in params:
setattr(self,p,request[self.id+'_'+p])
+
+
+ self.keys = filter(lambda x: len(x)>0 , self.keys)
+ if len(self.keys)==0: self.keys=None
+
def get(self,k,default_v=None):