messageFilter: make sure we do not choke if we expect a string but an array is given

This commit is contained in:
Mario
2026-03-27 21:53:04 +00:00
parent 89a1af1794
commit 8c4457db8b

View File

@@ -316,7 +316,7 @@ class MessageFilter
if (preg_match('/(.*?)\s~=\s(.*?)$/', $s, $matches)) {
$x = ((array_key_exists(trim($matches[1]),$item)) ? $item[trim($matches[1])] : EMPTY_STR);
if (stripos($x, trim($matches[2])) !== false) {
if (is_string($x) && stripos($x, trim($matches[2])) !== false) {
return true;
}
return false;