From f3ec8622e911dc5cd6f43c725865886e5ad00427 Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Tue, 8 Dec 2009 09:23:48 +1300 Subject: [PATCH] Restore support for current-user-principal property. --- inc/DAVResource.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/inc/DAVResource.php b/inc/DAVResource.php index 92d4b490..e66bdb9e 100644 --- a/inc/DAVResource.php +++ b/inc/DAVResource.php @@ -897,7 +897,7 @@ EOQRY; * Return general server-related properties for this URL */ function ResourceProperty( $tag, $prop, &$reply, &$denied ) { - global $c, $session; + global $c, $session, $request; // dbg_error_log( 'DAVResource', 'Processing "%s" on "%s".', $tag, $this->dav_name ); @@ -1013,6 +1013,10 @@ EOQRY; $prop->NewElement('supported-report-set', $this->BuildSupportedReports( $reply ) ); break; + case 'DAV::current-user-principal': + $prop->NewElement('current-user-principal', $reply->href( $request->principal->principal_url ) ); + break; + case 'SOME-DENIED-PROPERTY': /** @todo indicating the style for future expansion */ $denied[] = $reply->Tag($tag); break;