call_user_func_array
laravel/framework
Supported Versions: PHP 4 >= 4.0.4, PHP 5, PHP 7, PHP 8
Call a callback with an array of parameters
call_user_func_array
(callable
$callback
, array
$args
):
mixed
$result
=
$initial
;
foreach (
$this
as
$key
=>
$value
) {
$result
=
call_user_func_array
(
$callback
,
array_merge
(
$result
, [
$value
,
$key
]));
if (!
is_array
(
$result
)) {
throw new
UnexpectedValueException
(
sprintf
(
src/Illuminate/Collections/Traits/EnumeratesValues.php