Using array_map()
produces an unexpected result with array_search()
#3789
Labels
Milestone
array_map()
produces an unexpected result with array_search()
#3789
Bug report
Using
array_map()
produces an unexpected result witharray_search()
:However,
array_search()
can also returnfalse
(https://www.php.net/array_search):For now, I've added
/** @var array<int, string> $supported */
before the$supported
declaration as an workaround.Code snippet that reproduces the problem
Expected output
Expected no errors with the code snippet that reproduces the problem.
The text was updated successfully, but these errors were encountered: