Completed
Push — master ( 515575...4e0394 )
by Vytautas
9s
created

CollectionsManagerFactory::__invoke()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 7
c 0
b 0
f 0
ccs 3
cts 3
cp 1
rs 9.4285
cc 1
eloc 3
nc 1
nop 1
crap 1
1
<?php
2
3
namespace Svycka\Settings\Collection\Factory;
4
5
use Interop\Container\ContainerInterface;
6
use Svycka\Settings\Options\ModuleOptions;
7
use Svycka\Settings\Collection\CollectionsManager;
8
9
/**
10
 * @author Vytautas Stankus <[email protected]>
11
 * @license MIT
12
 */
13
final class CollectionsManagerFactory
14
{
15 1
    public function __invoke(ContainerInterface $container)
16
    {
17
        /** @var ModuleOptions $options */
18 1
        $options = $container->get(ModuleOptions::class);
19
20 1
        return new CollectionsManager($container, $options->getSettingsManager());
21
    }
22
}
23