aboutsummaryrefslogtreecommitdiffstats
path: root/apps/dav/lib/CardDAV/SystemAddressbook.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/dav/lib/CardDAV/SystemAddressbook.php')
-rw-r--r--apps/dav/lib/CardDAV/SystemAddressbook.php10
1 files changed, 10 insertions, 0 deletions
diff --git a/apps/dav/lib/CardDAV/SystemAddressbook.php b/apps/dav/lib/CardDAV/SystemAddressbook.php
index 17900fd033e..41e473ede63 100644
--- a/apps/dav/lib/CardDAV/SystemAddressbook.php
+++ b/apps/dav/lib/CardDAV/SystemAddressbook.php
@@ -45,6 +45,7 @@ use Sabre\DAV\Exception\NotFound;
use Sabre\DAV\ICollection;
use Sabre\VObject\Component\VCard;
use Sabre\VObject\Reader;
+use function array_filter;
use function array_unique;
class SystemAddressbook extends AddressBook {
@@ -296,4 +297,13 @@ class SystemAddressbook extends AddressBook {
}
throw new Forbidden();
}
+
+ public function getACL() {
+ return array_filter(parent::getACL(), function($acl) {
+ if (in_array($acl['privilege'], ['{DAV:}write', '{DAV:}all'], true)) {
+ return false;
+ }
+ return true;
+ });
+ }
}