fix TypeError: str_contains(): Argument #1 ($haystack) must be of type string, array given

This commit is contained in:
ralf 2023-06-15 11:25:34 +02:00
parent 67a1b107a7
commit ae12634639

View File

@ -3125,7 +3125,8 @@ class calendar_uiforms extends calendar_ui
{ {
return; return;
} }
if(str_contains($history['history']['status-widgets'][$row['status']], 'date')) if (is_string($history['history']['status-widgets'][$row['status']]) &&
str_contains($history['history']['status-widgets'][$row['status']], 'date'))
{ {
foreach(['old_value', 'new_value'] as $field) foreach(['old_value', 'new_value'] as $field)
{ {