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.

LazyLoadingCommandHandler::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 5
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 3
nc 1
nop 2
1
<?php
2
3
namespace Chief\Handlers;
4
5
use Chief\Command;
6
use Chief\CommandHandler;
7
use Chief\Container;
8
9
class LazyLoadingCommandHandler implements CommandHandler
10
{
11
    /**
12
     * @var \Chief\Container
13
     */
14
    protected $container;
15
16
    /**
17
     * @var string
18
     */
19
    protected $handlerName;
20
21
    /**
22
     * @param string $handlerName
23
     * @param Container $container
24
     */
25
    public function __construct($handlerName, Container $container)
26
    {
27
        $this->container = $container;
28
        $this->handlerName = $handlerName;
29
    }
30
31
    /**
32
     * Handle a command execution
33
     *
34
     * @param Command $command
35
     * @return mixed
36
     */
37
    public function handle(Command $command)
38
    {
39
        $handler = $this->container->make($this->handlerName);
40
41
        return $handler->handle($command);
42
    }
43
}
44