Passed
Pull Request — master (#65)
by Dmitriy
03:03
created

CommandResponse::getErrors()   A

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 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
ccs 0
cts 2
cp 0
rs 10
cc 1
nc 1
nop 0
crap 2
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Yiisoft\Yii\Debug\Api\Inspector;
6
7
class CommandResponse
8
{
9
    public const STATUS_OK = 'ok';
10
    public const STATUS_ERROR = 'ok';
11
12
    public function __construct(
13
        private string $status,
14
        private mixed $result,
15
        private array $errors = [],
16
    ) {
17
    }
18
19
    public function getStatus(): string
20
    {
21
        return $this->status;
22
    }
23
24
    public function getResult(): mixed
25
    {
26
        return $this->result;
27
    }
28
29
    public function getErrors(): array
30
    {
31
        return $this->errors;
32
    }
33
}
34