mirror of
https://github.com/Kozea/Radicale.git
synced 2025-08-01 18:18:31 +00:00
Additional type checking for getcontentcount prop
Tests keep failing due to static type checking for condition that won't occur due to earlier checking. Bringing checking into if statement.
This commit is contained in:
parent
2c13b8d2e0
commit
825464f102
1 changed files with 2 additions and 2 deletions
|
@ -274,8 +274,8 @@ def xml_propfind_response(
|
||||||
is404 = True
|
is404 = True
|
||||||
elif tag == xmlutils.make_clark("RADICALE:getcontentcount"):
|
elif tag == xmlutils.make_clark("RADICALE:getcontentcount"):
|
||||||
# Only for internal use by the web interface
|
# Only for internal use by the web interface
|
||||||
if is_collection and not collection.is_principal:
|
if isinstance(item, storage.BaseCollection) and not collection.is_principal:
|
||||||
element.text = str(sum(1 for entry in item.get_all()))
|
element.text = str(sum(1 for x in item.get_all()))
|
||||||
else:
|
else:
|
||||||
is404 = True
|
is404 = True
|
||||||
elif tag == xmlutils.make_clark("D:displayname"):
|
elif tag == xmlutils.make_clark("D:displayname"):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue