AppKernel   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 49
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 12

Importance

Changes 0
Metric Value
wmc 4
c 0
b 0
f 0
lcom 0
cbo 12
dl 0
loc 49
rs 10

4 Methods

Rating   Name   Duplication   Size   Complexity  
B registerBundles() 0 25 1
A registerContainerConfiguration() 0 4 1
A getCacheDir() 0 4 1
A getLogDir() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of the Blast Project package.
5
 *
6
 * Copyright (C) 2015-2017 Libre Informatique
7
 *
8
 * This file is licenced under the GNU LGPL v3.
9
 * For the full copyright and license information, please view the LICENSE.md
10
 * file that was distributed with this source code.
11
 */
12
13
use Symfony\Component\HttpKernel\Kernel;
14
use Symfony\Component\Config\Loader\LoaderInterface;
15
16
class AppKernel extends Kernel
17
{
18
    /*
19
     * @todo check what we need to register or not
20
     * @todo find a way to load this only on Functional test
21
     * @todo check what need to main composer.json
22
     */
23
24
    public function registerBundles()
25
    {
26
        $bundles = [
27
            new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
28
            new Symfony\Bundle\SecurityBundle\SecurityBundle(),
29
            new Symfony\Bundle\TwigBundle\TwigBundle(),
30
            // new Symfony\Bundle\MonologBundle\MonologBundle(),
0 ignored issues
show
Unused Code Comprehensibility introduced by
58% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
31
            // new Symfony\Bundle\SwiftmailerBundle\SwiftmailerBundle(),
0 ignored issues
show
Unused Code Comprehensibility introduced by
58% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
32
            new Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
33
            // new Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle(),
0 ignored issues
show
Unused Code Comprehensibility introduced by
58% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
34
35
            // Sonata
36
            new Sonata\CoreBundle\SonataCoreBundle(),
37
            new Sonata\BlockBundle\SonataBlockBundle(),
38
            new Knp\Bundle\MenuBundle\KnpMenuBundle(),
39
            new Sonata\DoctrineORMAdminBundle\SonataDoctrineORMAdminBundle(),
40
            new Sonata\AdminBundle\SonataAdminBundle(),
41
            // new Sonata\IntlBundle\SonataIntlBundle(),
0 ignored issues
show
Unused Code Comprehensibility introduced by
58% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
42
43
            // Blast
44
            new Blast\CoreBundle\BlastCoreBundle(),
45
        ];
46
47
        return $bundles;
48
    }
49
50
    public function registerContainerConfiguration(LoaderInterface $loader)
51
    {
52
        $loader->load(__DIR__ . '/config/config.yml');
53
    }
54
55
    public function getCacheDir()
56
    {
57
        return sys_get_temp_dir() . '/BlastCoreBundle/cache/' . $this->getEnvironment();
58
    }
59
60
    public function getLogDir()
61
    {
62
        return sys_get_temp_dir() . '/BlastCoreBundle/logs';
63
    }
64
}
65