[Zope-Checkins] CVS: Zope2 - PropertySheets.py:1.63.4.8
andreas@serenade.digicool.com
andreas@serenade.digicool.com
Tue, 10 Apr 2001 15:02:32 -0400
Update of /cvs-repository/Zope2/lib/python/OFS
In directory serenade.digicool.com:/tmp/cvs-serv32286/lib/python/OFS
Modified Files:
Tag: zope-2_3-branch
PropertySheets.py
Log Message:
Workaround for Collector #2150 (GoLIVE is confused by empty properties)
--- Updated File PropertySheets.py in package Zope2 --
--- PropertySheets.py 2001/04/10 14:13:29 1.63.4.7
+++ PropertySheets.py 2001/04/10 19:02:31 1.63.4.8
@@ -375,6 +375,14 @@
else:
# Quote non-xml items here?
attrs=''
+
+ # remove some empty properties to be send to clients
+ # that can't handle this in a proper way (GoLIVE)
+ # (ajung, Collector #2150)
+
+ if name in ['getlastmodified','getcontenttype'] \
+ and len(value)==0: continue
+
prop=' <n:%s%s>%s</n:%s>' % (name, attrs, value, name)
result.append(prop)
if not result: return ''