Changeset View
Changeset View
Standalone View
Standalone View
lib/Kolab/CalDAV/Calendar.php
Show First 20 Lines • Show All 79 Lines • ▼ Show 20 Lines | class Calendar extends \Sabre\CalDAV\Calendar | ||||
* - 'protected' (optional), indicating that this ACE is not allowed to be updated. | * - 'protected' (optional), indicating that this ACE is not allowed to be updated. | ||||
* | * | ||||
* @return array | * @return array | ||||
*/ | */ | ||||
public function getACL() | public function getACL() | ||||
{ | { | ||||
// return ACL information based on IMAP MYRIGHTS | // return ACL information based on IMAP MYRIGHTS | ||||
$rights = $this->storage->get_myrights(); | $rights = $this->storage->get_myrights(); | ||||
if ($rights && !PEAR::isError($rights)) { | if ($rights && !is_a($rights, 'PEAR_Error')) { | ||||
// user has at least read access to calendar folders listed | // user has at least read access to calendar folders listed | ||||
$acl = array( | $acl = array( | ||||
array( | array( | ||||
'privilege' => '{DAV:}read', | 'privilege' => '{DAV:}read', | ||||
'principal' => $this->calendarInfo['principaluri'], | 'principal' => $this->calendarInfo['principaluri'], | ||||
'protected' => true, | 'protected' => true, | ||||
), | ), | ||||
); | ); | ||||
▲ Show 20 Lines • Show All 78 Lines • Show Last 20 Lines |