In PROPFIND responses, add the not-yet-created collection type when it can be guessed
Maybe related to #795
This commit is contained in:
parent
f6ace2b6ec
commit
c3ce8fde38
@ -286,6 +286,10 @@ def _propfind_response(path, item, props, user):
|
|||||||
if item.is_leaf(item.path):
|
if item.is_leaf(item.path):
|
||||||
tag = ET.Element(_tag("C", item.resource_type))
|
tag = ET.Element(_tag("C", item.resource_type))
|
||||||
element.append(tag)
|
element.append(tag)
|
||||||
|
if not item.exists and item.resource_type:
|
||||||
|
# Collection not stored yet, but guessed resource type
|
||||||
|
tag = ET.Element(_tag("C", item.resource_type))
|
||||||
|
element.append(tag)
|
||||||
tag = ET.Element(_tag("D", "collection"))
|
tag = ET.Element(_tag("D", "collection"))
|
||||||
element.append(tag)
|
element.append(tag)
|
||||||
elif tag == _tag("D", "owner") and item.owner_url:
|
elif tag == _tag("D", "owner") and item.owner_url:
|
||||||
|
Loading…
Reference in New Issue
Block a user