Completed
Push — master ( b6ba3d...a4127c )
by Simonas
8s
created

RequestListener   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A onKernelRequest() 0 8 2
1
<?php
2
3
/*
4
 * This file is part of the ONGR package.
5
 *
6
 * (c) NFQ Technologies UAB <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace ONGR\SettingsBundle\EventListener;
13
14
use Symfony\Component\HttpKernel\Event\GetResponseEvent;
15
16
class RequestListener
17
{
18
    private $cache;
19
20
    public function __construct($cache)
21
    {
22
        $this->cache = $cache;
23
    }
24
25
    public function onKernelRequest(GetResponseEvent $event)
26
    {
27
        if (!$event->isMasterRequest()) {
28
            return;
29
        }
30
31
        // ...
32
    }
33
}
34