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.

RegisterCoreContainerAliases::bootstrap()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 19
Code Lines 11

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 11
nc 1
nop 1
dl 0
loc 19
ccs 0
cts 13
cp 0
crap 2
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
namespace Nip\Application\Bootstrap\Bootstrapers;
4
5
use Nip\Application;
6
use Nip\Application\ApplicationInterface;
7
use Nip\Container\Container;
8
use Nip\Dispatcher\Dispatcher;
9
use Nip\Http\Kernel\Kernel;
10
use Nip\Http\Kernel\KernelInterface;
11
use Nip\Router\Router;
12
13
/**
14
 * Class RegisterCoreContainerAliases
15
 * @package Nip\Application\Bootstrap\Bootstrapers
16
 */
17
class RegisterCoreContainerAliases extends AbstractBootstraper
18
{
19
    /**
20
     * Bootstrap the given application.
21
     *
22
     * @param Application $app
23
     * @return void
24
     */
25
    public function bootstrap(Application $app)
26
    {
27
        /** @var Container $container */
28
        $container = $app->getContainer();
29
30
        $container->share('app', $app);
31
        $container->alias('app', Application::class);
32
        $container->alias('app', ApplicationInterface::class);
33
34
        $container->share('container', $container);
35
36
        $container->share('kernel.http', function () use ($container) {
37
            return $container->get(Kernel::class);
38
        });
39
        $container->alias('kernel.http', KernelInterface::class);
40
41
        $container->alias('router', Router::class);
42
        $container->alias('dispatcher', Dispatcher::class);
43
    }
44
}
45