Skip to content

Commit

Permalink
use literal function calling syntax: improves readability of stack-tr…
Browse files Browse the repository at this point in the history
…aces a bit
  • Loading branch information
mindplay-dk committed Apr 6, 2024
1 parent d0e235c commit d87278b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Container.php
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ public function call(callable $callback, array $map = [])
{
$params = Reflection::createFromCallable($callback)->getParameters();

return call_user_func_array($callback, $this->resolve($params, $map));
return $callback(...$this->resolve($params, $map));
}

/**
Expand Down

0 comments on commit d87278b

Please sign in to comment.