From ba194038bf12477fc757d879a97e0e46699580cd Mon Sep 17 00:00:00 2001 From: nathangray Date: Mon, 31 May 2021 14:35:12 -0600 Subject: [PATCH] Silence "PHP Warning: count(): Parameter must be an array or an object that implements Countable" --- 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 f94a4806d1..d5e2f3431a 100644 --- a/calendar/inc/class.calendar_ical.inc.php +++ b/calendar/inc/class.calendar_ical.inc.php @@ -578,7 +578,7 @@ class calendar_ical extends calendar_boupdate $organizerUID = $event['owner']; } // do NOT use ORGANIZER for events without further participants or a different organizer - if (count($event['participants']) > 1 || !isset($event['participants'][$event['owner']]) || $event['owner'] != $this->user) + if (is_array($event['participants']) && (count($event['participants']) > 1 || !isset($event['participants'][$event['owner']])) || $event['owner'] != $this->user) { $attributes['ORGANIZER'] = $organizerURL; $parameters['ORGANIZER']['CN'] = $organizerCN;