Conditions | 1 |
Paths | 1 |
Total Lines | 16 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
17 | public function __invoke(ContainerInterface $container, $requestedName, array $options = null) |
||
18 | { |
||
19 | $eventManager = $container->get('Application')->getEventManager(); |
||
20 | |||
21 | $event = new MvcEvent(); |
||
22 | $event->setApplication($container->get('Application')); |
||
23 | $event->setTarget($container->get('Application')); |
||
24 | $event->setRequest($container->get('Request')); |
||
25 | $event->setRouter($container->get('Router')); |
||
26 | |||
27 | $routeMatch = new RouteMatch(array()); |
||
28 | |||
29 | $event->setRouteMatch($routeMatch); |
||
30 | |||
31 | return new ControllerService($eventManager, $event); |
||
32 | } |
||
33 | } |
||
34 |