summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2015-02-17 12:10:37 (GMT)
committerThomas Bruederli <bruederli@kolabsys.com>2015-02-17 12:10:37 (GMT)
commitf78af8b09f6f20858d4a8f6a69e590c03befdaa1 (patch)
tree6419a96af4d0f456e37bbb579745dbd9a2b8b862
parent8a90069071821f4cf2cdac6d7fce82cf12a32c11 (diff)
downloadroundcubemail-plugins-kolab-f78af8b09f6f20858d4a8f6a69e590c03befdaa1.tar.gz
Fix ical export after last commit
-rw-r--r--plugins/calendar/drivers/kolab/kolab_calendar.php2
-rw-r--r--plugins/calendar/drivers/kolab/kolab_driver.php6
2 files changed, 4 insertions, 4 deletions
diff --git a/plugins/calendar/drivers/kolab/kolab_calendar.php b/plugins/calendar/drivers/kolab/kolab_calendar.php
index 29bc01e..4316542 100644
--- a/plugins/calendar/drivers/kolab/kolab_calendar.php
+++ b/plugins/calendar/drivers/kolab/kolab_calendar.php
@@ -291,7 +291,7 @@ class kolab_calendar extends kolab_storage_folder_api
}
// find and merge exception for the first instance
- if (!empty($event['recurrence']) && is_array($event['recurrence']['EXCEPTIONS'])) {
+ if ($virtual && !empty($event['recurrence']) && is_array($event['recurrence']['EXCEPTIONS'])) {
$event_date = $event['start']->format('Ymd');
foreach ($event['recurrence']['EXCEPTIONS'] as $exception) {
$exdate = $exception['recurrence_date'] ? $exception['recurrence_date']->format('Ymd') : substr($exception['_instance'], 0, 8);
diff --git a/plugins/calendar/drivers/kolab/kolab_driver.php b/plugins/calendar/drivers/kolab/kolab_driver.php
index 3e3f0fc..0a9790c 100644
--- a/plugins/calendar/drivers/kolab/kolab_driver.php
+++ b/plugins/calendar/drivers/kolab/kolab_driver.php
@@ -1674,10 +1674,10 @@ class kolab_driver extends calendar_driver
unset($record['recurrence']);
// add instance identifier to first occurrence (master event)
+ // do not add 'recurrence_date' though in order to keep the master even being exported as such
if ($record['recurrence'] && !$record['recurrence_id'] && !$record['_instance']) {
- $recurrence_id_format = $event['allday'] ? 'Ymd' : 'Ymd\THis';
- $record['recurrence_date'] = $record['start'];
- $record['_instance'] = $record['recurrence_date']->format($recurrence_id_format);
+ $recurrence_id_format = $record['allday'] ? 'Ymd' : 'Ymd\THis';
+ $record['_instance'] = $record['start']->format($recurrence_id_format);
}
// remove internals