AccessHandler   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
dl 0
loc 15
ccs 0
cts 6
cp 0
rs 10
c 0
b 0
f 0
wmc 1
lcom 0
cbo 3

1 Method

Rating   Name   Duplication   Size   Complexity  
A logContextFormat() 0 9 1
1
<?php
2
/**
3
 * @author    jan huang <[email protected]>
4
 * @copyright 2016
5
 *
6
 * @see      https://www.github.com/janhuang
7
 * @see      https://fastdlabs.com
8
 */
9
10
namespace FastD\Logger;
11
12
/**
13
 * Class AccessHandler.
14
 */
15
class AccessHandler extends HandlerAbstract
16
{
17
    /**
18
     * @return array
19
     */
20
    protected function logContextFormat()
21
    {
22
        return [
23
            'ip' => get_local_ip(),
24
            'status' => response()->getStatusCode(),
25
            'get' => request()->getQueryParams(),
26
            'post' => request()->getParsedBody(),
27
        ];
28
    }
29
}
30