aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/sabre/dav/lib/CalDAV
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/sabre/dav/lib/CalDAV')
-rw-r--r--vendor/sabre/dav/lib/CalDAV/Backend/PDO.php2
-rw-r--r--vendor/sabre/dav/lib/CalDAV/Xml/Property/ScheduleCalendarTransp.php22
2 files changed, 7 insertions, 17 deletions
diff --git a/vendor/sabre/dav/lib/CalDAV/Backend/PDO.php b/vendor/sabre/dav/lib/CalDAV/Backend/PDO.php
index b1c013d62..95f1d49a6 100644
--- a/vendor/sabre/dav/lib/CalDAV/Backend/PDO.php
+++ b/vendor/sabre/dav/lib/CalDAV/Backend/PDO.php
@@ -1502,7 +1502,7 @@ SQL;
*/
function setPublishStatus($calendarId, $value) {
- throw new \Exception('Not implemented');
+ throw new \Sabre\DAV\Exception\NotImplemented('Not implemented');
}
diff --git a/vendor/sabre/dav/lib/CalDAV/Xml/Property/ScheduleCalendarTransp.php b/vendor/sabre/dav/lib/CalDAV/Xml/Property/ScheduleCalendarTransp.php
index 4a253e008..a82b8eff7 100644
--- a/vendor/sabre/dav/lib/CalDAV/Xml/Property/ScheduleCalendarTransp.php
+++ b/vendor/sabre/dav/lib/CalDAV/Xml/Property/ScheduleCalendarTransp.php
@@ -4,8 +4,8 @@ namespace Sabre\CalDAV\Xml\Property;
use Sabre\Xml\Element;
use Sabre\Xml\Reader;
+use Sabre\Xml\Deserializer;
use Sabre\Xml\Writer;
-use Sabre\Xml\Element\Elements;
use Sabre\CalDAV\Plugin;
/**
@@ -116,23 +116,13 @@ class ScheduleCalendarTransp implements Element {
*/
static function xmlDeserialize(Reader $reader) {
- $elems = Elements::xmlDeserialize($reader);
+ $elems = Deserializer\enum($reader, Plugin::NS_CALDAV);
- $value = null;
-
- foreach ($elems as $elem) {
- switch ($elem) {
- case '{' . Plugin::NS_CALDAV . '}opaque' :
- $value = self::OPAQUE;
- break;
- case '{' . Plugin::NS_CALDAV . '}transparent' :
- $value = self::TRANSPARENT;
- break;
- }
+ if (in_array('transparent', $elems)) {
+ $value = self::TRANSPARENT;
+ } else {
+ $value = self::OPAQUE;
}
- if (is_null($value))
- return null;
-
return new self($value);
}