summaryrefslogtreecommitdiffstats
path: root/apps/dav/lib/DAV/CustomPropertiesBackend.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/dav/lib/DAV/CustomPropertiesBackend.php')
-rw-r--r--apps/dav/lib/DAV/CustomPropertiesBackend.php15
1 files changed, 15 insertions, 0 deletions
diff --git a/apps/dav/lib/DAV/CustomPropertiesBackend.php b/apps/dav/lib/DAV/CustomPropertiesBackend.php
index bc822aee974..989d049fbd1 100644
--- a/apps/dav/lib/DAV/CustomPropertiesBackend.php
+++ b/apps/dav/lib/DAV/CustomPropertiesBackend.php
@@ -179,6 +179,21 @@ class CustomPropertiesBackend implements BackendInterface {
}
}
+ // substr of addressbooks/ => path is inside the CardDAV component
+ // three '/' => this a addressbook (no addressbook-home nor contact object)
+ if (str_starts_with($path, 'addressbooks/') && substr_count($path, '/') === 3) {
+ $allRequestedProps = $propFind->getRequestedProperties();
+ $customPropertiesForShares = [
+ '{DAV:}displayname',
+ ];
+
+ foreach ($customPropertiesForShares as $customPropertyForShares) {
+ if (in_array($customPropertyForShares, $allRequestedProps, true)) {
+ $requestedProps[] = $customPropertyForShares;
+ }
+ }
+ }
+
if (empty($requestedProps)) {
return;
}