[Zope-Checkins] CVS: Zope/lib/python/OFS - PropertySheets.py:1.95
Sidnei da Silva
sidnei at awkly.org
Wed Mar 31 10:57:37 EST 2004
Update of /cvs-repository/Zope/lib/python/OFS
In directory cvs.zope.org:/tmp/cvs-serv5794/lib/python/OFS
Modified Files:
PropertySheets.py
Log Message:
Apply patch by Josh LaPlace. Makes DAV 'supportedlock' actually check if the object implements the WriteLockInterface.
=== Zope/lib/python/OFS/PropertySheets.py 1.94 => 1.95 ===
--- Zope/lib/python/OFS/PropertySheets.py:1.94 Tue Mar 30 15:05:20 2004
+++ Zope/lib/python/OFS/PropertySheets.py Wed Mar 31 10:57:36 2004
@@ -565,10 +565,14 @@
return ''
def dav__supportedlock(self):
- return '\n <n:lockentry>\n' \
- ' <d:lockscope><d:exclusive/></d:lockscope>\n' \
- ' <d:locktype><d:write/></d:locktype>\n' \
- ' </n:lockentry>\n '
+ vself = self.v_self()
+ out = '\n'
+ if WriteLockInterface.isImplementedBy(vself):
+ out += (' <n:lockentry>\n'
+ ' <d:lockscope><d:exclusive/></d:lockscope>\n'
+ ' <d:locktype><d:write/></d:locktype>\n'
+ ' </n:lockentry>\n ')
+ return out
def dav__lockdiscovery(self):
security = getSecurityManager()
More information about the Zope-Checkins
mailing list