[Pkg-owncloud-commits] [php-sabredav] 104/275: Updating SCHEDULE-STATUS for organizers as well.

David Prévot taffit at moszumanska.debian.org
Thu Sep 25 14:55:57 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository php-sabredav.

commit 78e7602b1233e81d20d90a766907660d6cd3cb46
Author: Evert Pot <me at evertpot.com>
Date:   Wed Jul 23 17:15:09 2014 -0400

    Updating SCHEDULE-STATUS for organizers as well.
---
 lib/CalDAV/Schedule/Plugin.php | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git a/lib/CalDAV/Schedule/Plugin.php b/lib/CalDAV/Schedule/Plugin.php
index 9a6c91e..af1e3a0 100644
--- a/lib/CalDAV/Schedule/Plugin.php
+++ b/lib/CalDAV/Schedule/Plugin.php
@@ -451,11 +451,19 @@ class Plugin extends ServerPlugin {
 
             $this->deliver($message);
 
-            foreach($vObj->VEVENT->ATTENDEE as $attendee) {
+            if (isset($vObj->VEVENT->ORGANIZER) && ($vObj->VEVENT->ORGANIZER->getValue() === $message->recipient)) {
+
+                $vObj->VEVENT->ORGANIZER['SCHEDULE-STATUS'] = $message->scheduleStatus;
+
+            } else {
+
+                foreach($vObj->VEVENT->ATTENDEE as $attendee) {
+
+                    if ($attendee->getValue() === $message->recipient) {
+                        $attendee['SCHEDULE-STATUS'] = $message->scheduleStatus;
+                        break;
+                    }
 
-                if ($attendee->getValue() === $message->recipient) {
-                    $attendee['SCHEDULE-STATUS'] = $message->scheduleStatus;
-                    break;
                 }
 
             }

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabredav.git



More information about the Pkg-owncloud-commits mailing list