Skip to content

Commit

Permalink
Broker: add timezone to CANCEL messages
Browse files Browse the repository at this point in the history
If DTSTART and/or DTEND and other times are specified with a TZID, some clients
may fail reading the generated iCal data, since the VTIMEZONE definition is
missing.
  • Loading branch information
Bo Simonsen committed May 10, 2018
1 parent 881c9ab commit fa43866
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/ITip/Broker.php
Expand Up @@ -523,6 +523,11 @@ protected function parseEventForOrganizer(VCalendar $calendar, array $eventInfo,
// Creating the new iCalendar body.
$icalMsg = new VCalendar();
$icalMsg->METHOD = $message->method;

foreach ($calendar->select('VTIMEZONE') as $timezone) {
$icalMsg->add(clone $timezone);
}

$event = $icalMsg->add('VEVENT', [
'UID' => $message->uid,
'SEQUENCE' => $message->sequence,
Expand Down

1 comment on commit fa43866

@Julian1998
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bosim Hey, I know this is a little bit older. But why didn't you provide this fix for all method values? We got a similar problem for other methods as well. Was there a reason for this? Otherwise I would change it to affect all methods in general.

Please sign in to comment.