From de6d609752c1a095fe85f5c14c060bdba4772e2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Lehrke?= Date: Mon, 8 Feb 2010 20:42:37 +0000 Subject: [PATCH] Fix CalDAV missing event ID --- calendar/inc/class.calendar_ical.inc.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/calendar/inc/class.calendar_ical.inc.php b/calendar/inc/class.calendar_ical.inc.php index 17b6e6e0c3..f000975538 100644 --- a/calendar/inc/class.calendar_ical.inc.php +++ b/calendar/inc/class.calendar_ical.inc.php @@ -892,6 +892,10 @@ class calendar_ical extends calendar_boupdate { $event['uid'] = $event_info['stored_event']['uid']; // restore the UID if it was not delivered } + elseif (empty($event['id'])) + { + $event['id'] = $event_info['stored_event']['id']; // CalDAV does only provide UIDs + } if ($merge) { // overwrite with server data for merge @@ -1210,7 +1214,7 @@ class calendar_ical extends calendar_boupdate if ($this->log) { $event_info['stored_event'] = $this->read($event_info['stored_event']['id']); - error_log(__FILE__.'['.__LINE__.'] '.__METHOD__."()\n" . + error_log(__FILE__.'['.__LINE__.'] '.__METHOD__."()[$updated_id]\n" . array2string($event_info['stored_event'])."\n",3,$this->logfile); } }