[Pkg-owncloud-commits] [php-sabredav] 04/09: baseUri -> contextUri

David Prévot taffit at moszumanska.debian.org
Mon Jun 1 22:42:45 UTC 2015


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

taffit pushed a commit to tag 3.0.0-beta2
in repository php-sabredav.

commit d7fb99d2a2920e916fb3c458051e9565dddeff9a
Author: Evert Pot <me at evertpot.com>
Date:   Tue May 26 13:34:03 2015 -0400

    baseUri -> contextUri
---
 lib/CalDAV/Notifications/Plugin.php         | 1 +
 lib/CalDAV/Xml/Notification/Invite.php      | 4 ++--
 lib/CalDAV/Xml/Notification/InviteReply.php | 2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/lib/CalDAV/Notifications/Plugin.php b/lib/CalDAV/Notifications/Plugin.php
index a9b4bce..effc29e 100644
--- a/lib/CalDAV/Notifications/Plugin.php
+++ b/lib/CalDAV/Notifications/Plugin.php
@@ -137,6 +137,7 @@ class Plugin extends ServerPlugin {
             return;
 
         $writer = $this->server->xml->getWriter();
+        $writer->contextUri = $request->getUrl();
         $writer->openMemory();
         $writer->startDocument('1.0', 'UTF-8');
         $writer->startElement('{http://calendarserver.org/ns/}notification');
diff --git a/lib/CalDAV/Xml/Notification/Invite.php b/lib/CalDAV/Xml/Notification/Invite.php
index 8811a33..adee95b 100644
--- a/lib/CalDAV/Xml/Notification/Invite.php
+++ b/lib/CalDAV/Xml/Notification/Invite.php
@@ -226,7 +226,7 @@ class Invite implements NotificationInterface {
         }
 
         $writer->writeElement($cs . 'hosturl', [
-            '{DAV:}href' => $writer->baseUri . $this->hostUrl
+            '{DAV:}href' => $writer->contextUri . $this->hostUrl
             ]);
 
         if ($this->summary) {
@@ -247,7 +247,7 @@ class Invite implements NotificationInterface {
         if (strtolower(substr($this->organizer, 0, 7)) === 'mailto:') {
             $writer->writeElement('{DAV:}href', $this->organizer);
         } else {
-            $writer->writeElement('{DAV:}href', $writer->baseUri . $this->organizer);
+            $writer->writeElement('{DAV:}href', $writer->contextUri . $this->organizer);
         }
         if ($this->commonName) {
             $writer->writeElement($cs . 'common-name', $this->commonName);
diff --git a/lib/CalDAV/Xml/Notification/InviteReply.php b/lib/CalDAV/Xml/Notification/InviteReply.php
index 08032f3..1b99d5e 100644
--- a/lib/CalDAV/Xml/Notification/InviteReply.php
+++ b/lib/CalDAV/Xml/Notification/InviteReply.php
@@ -170,7 +170,7 @@ class InviteReply implements NotificationInterface {
         }
 
         $writer->writeElement($cs . 'hosturl', [
-            '{DAV:}href' => $writer->baseUri . $this->hostUrl
+            '{DAV:}href' => $writer->contextUri . $this->hostUrl
             ]);
 
         if ($this->summary) {

-- 
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