Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[jan] Handle gracefully if the base event of an imported recurrence e…
…xception is no longer recurring (Bug #14249).
  • Loading branch information
yunosh committed Feb 12, 2016
1 parent 92a567c commit ab350dd
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
2 changes: 2 additions & 0 deletions kronolith/docs/CHANGES
Expand Up @@ -2,6 +2,8 @@
v4.2.15-git
-----------

[jan] Handle gracefully if the base event of an imported recurrence exception
is no longer recurring (Bug #14249).


-------
Expand Down
12 changes: 8 additions & 4 deletions kronolith/lib/Event.php
Expand Up @@ -1444,10 +1444,14 @@ protected function _handlevEventRecurrence($vEvent)
$this->uid = null;
try {
$originalEvent = $this->getDriver()->getByUID($this->baseid);
$originalEvent->recurrence->addException($originaldt->format('Y'),
$originaldt->format('m'),
$originaldt->format('d'));
$originalEvent->save();
if ($originalEvent->recurrence) {
$originalEvent->recurrence->addException(
$originaldt->format('Y'),
$originaldt->format('m'),
$originaldt->format('d')
);
$originalEvent->save();
}
} catch (Horde_Exception_NotFound $e) {
throw new Kronolith_Exception(_("Unable to locate original event series."));
}
Expand Down
4 changes: 2 additions & 2 deletions kronolith/package.xml
Expand Up @@ -33,7 +33,7 @@
</stability>
<license uri="http://www.horde.org/licenses/gpl">GPL-2.0</license>
<notes>
*
* [jan] Handle gracefully if the base event of an imported recurrence exception is no longer recurring (Bug #14249).
</notes>
<contents>
<dir baseinstalldir="/" name="/">
Expand Down Expand Up @@ -2680,7 +2680,7 @@
<date>2016-02-10</date>
<license uri="http://www.horde.org/licenses/gpl">GPL-2.0</license>
<notes>
*
* [jan] Handle gracefully if the base event of an imported recurrence exception is no longer recurring (Bug #14249).
</notes>
</release>
</changelog>
Expand Down

0 comments on commit ab350dd

Please sign in to comment.