From 580c3f4ffe9608d2beb56d418c68b3b112420e76 Mon Sep 17 00:00:00 2001 From: Mario Date: Sun, 10 Nov 2019 12:49:51 +0000 Subject: another bulk of composer updates (cherry picked from commit 6685381fd8db507493c3d7c1793f8c05c681bbce) --- .../sabre/dav/lib/CalDAV/Subscriptions/Plugin.php | 43 +++++++++------------- 1 file changed, 18 insertions(+), 25 deletions(-) (limited to 'vendor/sabre/dav/lib/CalDAV/Subscriptions/Plugin.php') diff --git a/vendor/sabre/dav/lib/CalDAV/Subscriptions/Plugin.php b/vendor/sabre/dav/lib/CalDAV/Subscriptions/Plugin.php index 877d96c6c..238866894 100644 --- a/vendor/sabre/dav/lib/CalDAV/Subscriptions/Plugin.php +++ b/vendor/sabre/dav/lib/CalDAV/Subscriptions/Plugin.php @@ -1,5 +1,7 @@ resourceTypeMapping['Sabre\\CalDAV\\Subscriptions\\ISubscription'] = '{http://calendarserver.org/ns/}subscribed'; @@ -39,7 +40,6 @@ class Plugin extends ServerPlugin { 'Sabre\\DAV\\Xml\\Property\\Href'; $server->on('propFind', [$this, 'propFind'], 150); - } /** @@ -50,21 +50,19 @@ class Plugin extends ServerPlugin { * * @return array */ - function getFeatures() { - + public function getFeatures() + { return ['calendarserver-subscribed']; - } /** * Triggered after properties have been fetched. * * @param PropFind $propFind - * @param INode $node - * @return void + * @param INode $node */ - function propFind(PropFind $propFind, INode $node) { - + public function propFind(PropFind $propFind, INode $node) + { // There's a bunch of properties that must appear as a self-closing // xml-element. This event handler ensures that this will be the case. $props = [ @@ -74,13 +72,10 @@ class Plugin extends ServerPlugin { ]; foreach ($props as $prop) { - - if ($propFind->getStatus($prop) === 200) { + if (200 === $propFind->getStatus($prop)) { $propFind->set($prop, '', 200); } - } - } /** @@ -91,10 +86,9 @@ class Plugin extends ServerPlugin { * * @return string */ - function getPluginName() { - + public function getPluginName() + { return 'subscriptions'; - } /** @@ -108,13 +102,12 @@ class Plugin extends ServerPlugin { * * @return array */ - function getPluginInfo() { - + public function getPluginInfo() + { return [ - 'name' => $this->getPluginName(), + 'name' => $this->getPluginName(), 'description' => 'This plugin allows users to store iCalendar subscriptions in their calendar-home.', - 'link' => null, + 'link' => null, ]; - } } -- cgit v1.2.3