GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( d27e94...54e4b3 )
by Alexander
02:17
created

BookingActionFactory   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 9
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 0
cbo 2
dl 0
loc 9
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __invoke() 0 6 1
1
<?php
2
/*
3
 * This file is part of the prooph/cargo-sample2.
4
 * (c) Alexander Miertsch <[email protected]>
5
 *
6
 * For the full copyright and license information, please view the LICENSE
7
 * file that was distributed with this source code.
8
 * 
9
 * Date: 06.12.2015 - 11:13 PM
10
 */
11
namespace Codeliner\CargoBackend\Infrastructure\Container\Application\Action;
12
13
use Assert\Assertion;
14
use Codeliner\CargoBackend\Application\Booking\BookingService;
15
use Interop\Container\ContainerInterface;
16
17
/**
18
 * Class BookingActionFactory
19
 *
20
 * @package Codeliner\CargoBackend\Container\Application\Action
21
 */
22
final class BookingActionFactory
23
{
24
    public function __invoke(ContainerInterface $container, $requestedService)
25
    {
26
        Assertion::classExists($requestedService);
27
28
        return new $requestedService($container->get(BookingService::class));
29
    }
30
}
31