Skip to content

Commit

Permalink
Don't ignore components with RECURRENCE-ID attributes if we have noth…
Browse files Browse the repository at this point in the history
…ing else.

The iTip might be a result of an update to an exception etc... Fixes
Bug: 13777
  • Loading branch information
mrubinsk committed Jan 8, 2015
1 parent 518911e commit f80ed69
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions imp/lib/Mime/Viewer/Itip.php
Expand Up @@ -125,16 +125,18 @@ protected function _renderInline()
}

$out = array();
$exceptions = array();
$components = $vCal->getComponents();
foreach ($components as $key => $component) {
switch ($component->getType()) {
case 'vEvent':
try {
if ($component->getAttribute('RECURRENCE-ID')) {
break;
$exceptions[] = $this->_vEvent($component, $key, $method, $components);
}
} catch (Horde_ICalendar_Exception $e) {}
$out[] = $this->_vEvent($component, $key, $method, $components);
} catch (Horde_ICalendar_Exception $e) {
$out[] = $this->_vEvent($component, $key, $method, $components);
}
break;

case 'vTodo':
Expand All @@ -156,6 +158,13 @@ protected function _renderInline()
}
}

// If we don't have any other parts, any exceptions should be shown
// since this is likely an update to a series instance such as a
// cancellation etc...
if (empty($out)) {
$out = $exceptions;
}

$view = $this->_getViewOb();
$view->formid = $imple->getDomId();
$view->out = implode('', $out);
Expand Down

0 comments on commit f80ed69

Please sign in to comment.