From d88e1ca00798d2f827ab127caefe5f99d6be27e9 Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Thu, 5 Jul 2012 12:23:27 +1200 Subject: [PATCH] Fix support for missing or on multiget/query reports. --- inc/caldav-REPORT-cardquery.php | 3 ++- inc/caldav-REPORT-multiget.php | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/inc/caldav-REPORT-cardquery.php b/inc/caldav-REPORT-cardquery.php index 0aefbe62..06eff762 100644 --- a/inc/caldav-REPORT-cardquery.php +++ b/inc/caldav-REPORT-cardquery.php @@ -29,7 +29,7 @@ switch( $proptype ) { break; case 'DAV::allprop': - $properties['allprop'] = 1; + $properties['DAV::allprop'] = 1; if ( $qry_content[1]->GetNSTag() == 'DAV::include' ) { foreach( $qry_content[1]->GetElements() AS $k => $v ) { $include_properties[] = $v->GetNSTag(); /** $include_properties is referenced in DAVResource where allprop is expanded */ @@ -41,6 +41,7 @@ switch( $proptype ) { default: $properties[$proptype] = 1; } +if ( empty($properties) ) $properties['DAV::allprop'] = 1; /** * There can only be *one* FILTER element. diff --git a/inc/caldav-REPORT-multiget.php b/inc/caldav-REPORT-multiget.php index 18face2c..87207c9a 100644 --- a/inc/caldav-REPORT-multiget.php +++ b/inc/caldav-REPORT-multiget.php @@ -38,7 +38,7 @@ switch( $proptype ) { break; case 'DAV::allprop': - $properties['allprop'] = 1; + $properties['DAV::allprop'] = 1; if ( $qry_content[1]->GetNSTag() == 'DAV::include' ) { foreach( $qry_content[1]->GetElements() AS $k => $v ) { $include_properties[] = $v->GetNSTag(); /** $include_properties is referenced in DAVResource where allprop is expanded */ @@ -50,6 +50,7 @@ switch( $proptype ) { default: $properties[$proptype] = 1; } +if ( empty($properties) ) $properties['DAV::allprop'] = 1; $collection = new DAVResource($request->path); $bound_from = $collection->bound_from();