Skip to content

Commit 7c808e6

Browse files
committed
Optimize perf by replacing call_user_func with dynamic vars
1 parent cda9b42 commit 7c808e6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Loader/ObjectRouteLoader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public function load($resource, $type = null)
6767
throw new \BadMethodCallException(sprintf('Method "%s" not found on "%s" when importing routing resource "%s"', $method, \get_class($loaderObject), $resource));
6868
}
6969

70-
$routeCollection = \call_user_func(array($loaderObject, $method), $this);
70+
$routeCollection = $loaderObject->$method($this);
7171

7272
if (!$routeCollection instanceof RouteCollection) {
7373
$type = \is_object($routeCollection) ? \get_class($routeCollection) : \gettype($routeCollection);

0 commit comments

Comments
 (0)