Calendar: Avoid error in link_title if participants is not an array

This commit is contained in:
nathan 2022-10-18 11:49:36 -06:00
parent 723308e525
commit a1f87eb419

View File

@ -2014,7 +2014,7 @@ class calendar_bo
$extra_fields [$val] = $this->format_date($event[$val]); $extra_fields [$val] = $this->format_date($event[$val]);
break; break;
case 'participants': case 'participants':
foreach (array_keys($event[$val]) as $key) foreach(array_keys((array)$event[$val]) as $key)
{ {
$extra_fields [$val] = Api\Accounts::id2name($key, 'account_fullname'); $extra_fields [$val] = Api\Accounts::id2name($key, 'account_fullname');
} }