Passed
Push — master ( 89f24e...8c4dad )
by Sylvain
08:05
created

Extras::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 18
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 18
ccs 3
cts 3
cp 1
crap 1
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Ecodev\Felix\Log\Formatter;
6
7
use Laminas\Log\Formatter\Simple;
8
9
/**
10
 * Simple formatter that show the Felix extras fields
11
 */
12
final class Extras extends Simple
13
{
14
    /**
15
     * Class constructor
16
     */
17 4
    public function __construct()
18
    {
19 4
        $format = '
20
Time    : %timestamp%
21
Priority: %priorityName% (%priority%)
22
Login   : %login%
23
URL     : %url%
24
REFERER : %referer%
25
IP      : %ip%
26
27
REQUEST:
28
%request%
29
30
MESSAGE:
31
%message%
32
33
';
34 4
        parent::__construct($format);
35 4
    }
36
}
37