From 81cbc00ae34a4600fa7fc8261602d1aa1882bc42 Mon Sep 17 00:00:00 2001 From: ralf Date: Thu, 4 Jul 2024 10:50:07 +0200 Subject: [PATCH] fix RDATE exported with Z, if EXDATE was also exported --- calendar/inc/class.calendar_ical.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/calendar/inc/class.calendar_ical.inc.php b/calendar/inc/class.calendar_ical.inc.php index 253f830628..0c6c9a6e60 100644 --- a/calendar/inc/class.calendar_ical.inc.php +++ b/calendar/inc/class.calendar_ical.inc.php @@ -1109,7 +1109,7 @@ class calendar_ical extends calendar_boupdate // hack to fix iCalendar exporting EXDATE|RDATE always postfixed with a Z // EXDATE can have multiple values and therefore be folded into multiple lines - return preg_replace_callback("/\n(EXDATE|RDATE);TZID=[^:]+:[0-9TZ \r\n,]+/", static function($matches) + return preg_replace_callback("/^(EXDATE|RDATE);TZID=[^:]+:[0-9TZ \r\n,]+/m", static function($matches) { return preg_replace('/([0-9 ])Z/', '$1', $matches[0]); }, $retval);