ServiceConfig::getStaticApiToken()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
ccs 0
cts 2
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
declare(strict_types=1);
3
4
5
namespace Xervice\Service;
6
7
8
use Xervice\Core\Config\AbstractConfig;
9
10
class ServiceConfig extends AbstractConfig
11
{
12
    const STATIC_API_TOKEN_LIST = 'static.api.token.list';
13
14
    const DEBUG_ACTIVE = 'debug.active';
15
16
    /**
17
     * @return array
18
     * @throws \Xervice\Config\Exception\ConfigNotFound
19
     */
20
    public function getStaticApiToken() : array
21
    {
22
        return $this->get(self::STATIC_API_TOKEN_LIST, []);
23
    }
24
25
    /**
26
     * @return bool
27
     * @throws \Xervice\Config\Exception\ConfigNotFound
28
     */
29 1
    public function isDebug() : bool
30
    {
31 1
        return $this->get(self::DEBUG_ACTIVE, false);
32
    }
33
}