Failed Conditions
Push — master ( b69c62...c6060f )
by Sébastien
02:49
created

ApiAuthTokenHandlerFactory   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 8
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 8
c 0
b 0
f 0
ccs 0
cts 5
cp 0
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __invoke() 0 6 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace App\Handler;
6
7
use App\Service\TokenManager;
8
use Psr\Container\ContainerInterface;
9
10
class ApiAuthTokenHandlerFactory
11
{
12
    public function __invoke(ContainerInterface $container): ApiAuthTokenHandler
13
    {
14
        $userProvider = $container->get(\App\Security\ContredanseUserProvider::class);
15
        $tokenService = $container->get(TokenManager::class);
16
17
        return new ApiAuthTokenHandler($userProvider, $tokenService);
18
    }
19
}
20