allow users to send PropPatch request when calendar is group-shared with them

Signed-off-by: Georg Ehrke <developer@georgehrke.com>
This commit is contained in:
Georg Ehrke 2017-06-08 09:21:56 +02:00
parent a74901fce1
commit 0f1d47cdf3
No known key found for this signature in database
GPG Key ID: 9D98FD9380A1CB43
2 changed files with 12 additions and 0 deletions

View File

@ -135,6 +135,12 @@ class Calendar extends \Sabre\CalDAV\Calendar implements IShareable {
'principal' => parent::getOwner(),
'protected' => true,
];
} else {
$acl[] = [
'privilege' => '{DAV:}write-properties',
'principal' => parent::getOwner(),
'protected' => true,
];
}
}
if ($this->isPublic()) {

View File

@ -205,6 +205,12 @@ class CalendarTest extends TestCase {
'principal' => 'user2',
'protected' => true
];
} else {
$expectedAcl[] = [
'privilege' => '{DAV:}write-properties',
'principal' => 'user2',
'protected' => true
];
}
}
$this->assertEquals($expectedAcl, $acl);