From 18285429e9d9edc3a4055b930172a6155788b3e1 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Tue, 1 Oct 2013 11:38:34 +0000 Subject: [PATCH] * CalDAV/CardDAV: fixed not working propfind-request to single resource in calendar/addressbook collection --- addressbook/inc/class.addressbook_groupdav.inc.php | 4 ++++ calendar/inc/class.calendar_groupdav.inc.php | 2 +- infolog/inc/class.infolog_groupdav.inc.php | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/addressbook/inc/class.addressbook_groupdav.inc.php b/addressbook/inc/class.addressbook_groupdav.inc.php index 43201f4598..08481effa2 100644 --- a/addressbook/inc/class.addressbook_groupdav.inc.php +++ b/addressbook/inc/class.addressbook_groupdav.inc.php @@ -208,6 +208,10 @@ class addressbook_groupdav extends groupdav_handler // detect sync-collection report $sync_collection_report = isset($filter[0]) && strpos($filter[0], 'contact_modified>') === 0; + if (isset($filter_in[self::$path_attr]) && !is_array($filter_in[self::$path_attr])) + { + $filter_in[self::$path_attr] = (array)$filter_in[self::$path_attr]; + } $requested_multiget_ids =& $filter_in[self::$path_attr]; $files = array(); diff --git a/calendar/inc/class.calendar_groupdav.inc.php b/calendar/inc/class.calendar_groupdav.inc.php index d732515c51..cbd9812df7 100644 --- a/calendar/inc/class.calendar_groupdav.inc.php +++ b/calendar/inc/class.calendar_groupdav.inc.php @@ -263,7 +263,7 @@ class calendar_groupdav extends groupdav_handler $filter['offset'] = $start[0]; $filter['num_rows'] = $start[1]; } - $requested_multiget_ids = $filter['query'][self::$path_attr]; + $requested_multiget_ids = (array)$filter['query'][self::$path_attr]; $sync_collection = strpos($filter['query'][0],'cal_modified>') === 0 && $filter['filter'] == 'everything'; $events =& $this->bo->search($filter); diff --git a/infolog/inc/class.infolog_groupdav.inc.php b/infolog/inc/class.infolog_groupdav.inc.php index 090d9f60a6..84a4b1ea36 100644 --- a/infolog/inc/class.infolog_groupdav.inc.php +++ b/infolog/inc/class.infolog_groupdav.inc.php @@ -254,7 +254,7 @@ class infolog_groupdav extends groupdav_handler $offset = 0; } - $requested_multiget_ids = $filter[self::$path_attr]; + $requested_multiget_ids = (array)$filter[self::$path_attr]; $files = array(); // ToDo: add parameter to only return id & etag