aboutsummaryrefslogtreecommitdiffstats
path: root/apps/dav/lib/CardDAV/CardDavBackend.php
diff options
context:
space:
mode:
authorAnna Larch <anna@nextcloud.com>2023-07-21 12:33:00 +0200
committerAnna <anna@nextcloud.com>2023-08-16 09:11:01 +0200
commit6bd78917d31ab9932a9f394197007feea46bcbd8 (patch)
tree00d2cca98a1c82485c82fab4dc3ce54787c61c2d /apps/dav/lib/CardDAV/CardDavBackend.php
parent091c1edd21f5736523f9243b88580896fd6aec82 (diff)
downloadnextcloud-server-6bd78917d31ab9932a9f394197007feea46bcbd8.tar.gz
nextcloud-server-6bd78917d31ab9932a9f394197007feea46bcbd8.zip
fix(CardDAV): set owner-principal, displayname properties for SAB
Signed-off-by: Anna Larch <anna@nextcloud.com>
Diffstat (limited to 'apps/dav/lib/CardDAV/CardDavBackend.php')
-rw-r--r--apps/dav/lib/CardDAV/CardDavBackend.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/apps/dav/lib/CardDAV/CardDavBackend.php b/apps/dav/lib/CardDAV/CardDavBackend.php
index 045ad4d1385..d7bad8d74ca 100644
--- a/apps/dav/lib/CardDAV/CardDavBackend.php
+++ b/apps/dav/lib/CardDAV/CardDavBackend.php
@@ -311,10 +311,12 @@ class CardDavBackend implements BackendInterface, SyncSupport {
'{' . Plugin::NS_CARDDAV . '}addressbook-description' => $row['description'],
'{http://calendarserver.org/ns/}getctag' => $row['synctoken'],
'{http://sabredav.org/ns}sync-token' => $row['synctoken'] ?: '0',
+
];
// system address books are always read only
if ($principal === 'principals/system/system') {
+ $addressBook['{' . \OCA\DAV\DAV\Sharing\Plugin::NS_OWNCLOUD . '}owner-principal'] = $row['principaluri'];
$addressBook['{' . \OCA\DAV\DAV\Sharing\Plugin::NS_OWNCLOUD . '}read-only'] = true;
}