Fix fatal error by validating array key type before using in empty() (#34295)

This commit is contained in:
atm-irvine 2025-05-27 16:04:25 +02:00 committed by GitHub
parent 5771b6bd1f
commit de4990a0fd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1239,6 +1239,9 @@ class ActionComm extends CommonObject
if (!is_array($val)) { // For backward compatibility when val=id
$val = array('id' => $val);
}
if (!isset($val['id']) || !is_scalar($val['id'])) {
continue;
}
if (!empty($already_inserted[$val['id']])) {
continue;
}