IndexControllerFactory   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 5
dl 0
loc 13
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __invoke() 0 11 1
1
<?php
2
3
namespace Application\Controller\Factory;
4
5
use Laminas\ServiceManager\Factory\FactoryInterface;
6
use Interop\Container\ContainerInterface;
7
use Application\Controller\IndexController;
8
use Application\Service\BotParserCache;
9
10
class IndexControllerFactory implements FactoryInterface
11
{
12
    public function __invoke(
13
        ContainerInterface $container,
14
        $requestedName,
15
        array $options = null
16
    ) {
17
        $config = $container->get('configuration');
18
        $config = $config['idlerpg'];
19
20
        $parser = $container->get(BotParserCache::class);
21
22
        return new IndexController($config, $parser);
23
    }
24
}
25