Skip to content

Commit cac97eb

Browse files
committed
Check the external ID key parameter before searching it in the external keys array
In PHP 8.5 passing null as the key parameter for array_key_exists() is deprecated.
1 parent 5669885 commit cac97eb

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/AbraFlexi/RO.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2137,7 +2137,7 @@ public function getExternalID($want = null)
21372137
{
21382138
$ids = (array) $this->getExternalIDs();
21392139

2140-
return \array_key_exists($want, $ids) ? $ids[$want] : current($ids);
2140+
return $want !== null && \array_key_exists($want, $ids) ? $ids[$want] : current($ids);
21412141
}
21422142

21432143
/**

0 commit comments

Comments
 (0)