DebugHandler   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 10
ccs 0
cts 5
cp 0
rs 10
c 0
b 0
f 0
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A handle() 0 5 2
1
<?php
2
declare(strict_types=1);
3
4
5
namespace Xervice\Service\Handler\Handler;
6
7
8
use Symfony\Component\Debug\Debug;
9
use Xervice\Service\Handler\HandlerInterface;
10
11
class DebugHandler implements HandlerInterface
12
{
13
    /**
14
     * @param bool $isDebug
15
     */
16
    public function handle(bool $isDebug): void
17
    {
18
        if ($isDebug) {
19
            putenv("APP_DEBUG=true");
20
            Debug::enable();
21
        }
22
    }
23
24
}