From 579b2020012734365ca61bb896d9e2bd948a8e8e Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Mon, 23 Mar 2015 20:00:10 +0000 Subject: [PATCH] - Fix $$Recurrence$$ notification placeholder to be empty (not missing) for non-recurring events - Avoid warning in get_link_options by making unused parameter optional --- calendar/inc/class.calendar_bo.inc.php | 2 +- calendar/inc/class.calendar_boupdate.inc.php | 11 ++++------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/calendar/inc/class.calendar_bo.inc.php b/calendar/inc/class.calendar_bo.inc.php index ecb1e741ff..8d5d57a15c 100644 --- a/calendar/inc/class.calendar_bo.inc.php +++ b/calendar/inc/class.calendar_bo.inc.php @@ -1834,7 +1834,7 @@ class calendar_bo * @param type $event * @return array array of selected calendar fields */ - function get_link_options ($event) + function get_link_options ($event = array()) { $options = array ( 'end' => lang('End date'), diff --git a/calendar/inc/class.calendar_boupdate.inc.php b/calendar/inc/class.calendar_boupdate.inc.php index af6378356f..128263613c 100644 --- a/calendar/inc/class.calendar_boupdate.inc.php +++ b/calendar/inc/class.calendar_boupdate.inc.php @@ -1775,13 +1775,10 @@ class calendar_boupdate extends calendar_bo ); // Repeated Events - if($event['recur_type'] != MCAL_RECUR_NONE) - { - $var['recur_type'] = Array( - 'field' => lang('Repetition'), - 'data' => $this->recure2string($event), - ); - } + $var['recur_type'] = Array( + 'field' => lang('Repetition'), + 'data' => ($event['recur_type'] != MCAL_RECUR_NONE) ? $this->recure2string($event) : '', + ); return $var; }