Return / for principal-collection-set

From RFC3744: This protected property of a resource contains a set of URLs that identify the root collections that contain the principals that are available on the server that implements this resource.
This commit is contained in:
Unrud 2016-08-01 20:44:04 +02:00
parent 8f91190949
commit 7aa481aaa1

View File

@ -592,8 +592,11 @@ def _propfind_response(path, item, props, user, write=False):
element.text = item.etag element.text = item.etag
elif tag == _tag("D", "getlastmodified"): elif tag == _tag("D", "getlastmodified"):
element.text = item.last_modified element.text = item.last_modified
elif tag in (_tag("D", "principal-collection-set"), elif tag == _tag("D", "principal-collection-set"):
_tag("C", "calendar-user-address-set"), tag = ET.Element(_tag("D", "href"))
tag.text = _href(collection, "/")
element.append(tag)
elif tag in (_tag("C", "calendar-user-address-set"),
_tag("D", "principal-URL"), _tag("D", "principal-URL"),
_tag("CR", "addressbook-home-set"), _tag("CR", "addressbook-home-set"),
_tag("C", "calendar-home-set")): _tag("C", "calendar-home-set")):