JsonConfig::readConfig()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 1
dl 0
loc 4
rs 10
c 0
b 0
f 0
ccs 3
cts 3
cp 1
crap 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace BlueEvent\Event\Config;
6
7
use Laminas\Config\Reader\Json;
8
9
class JsonConfig implements ConfigReader
10
{
11
    /**
12
     * @param string $path
13
     * @return array
14
     */
15 2
    public function readConfig(string $path): array
16
    {
17 2
        $reader = new Json();
18 2
        return $reader->fromFile($path);
19
    }
20
}
21