Total Complexity | 3 |
Total Lines | 60 |
Duplicated Lines | 0 % |
Coverage | 7.14% |
Changes | 0 |
1 | <?php |
||
22 | class Row extends \Bluz\Db\Row |
||
23 | { |
||
24 | use Validator; |
||
25 | |||
26 | /** |
||
27 | * {@inheritdoc} |
||
28 | * |
||
29 | * @throws \Bluz\Validator\Exception\ComponentException |
||
30 | */ |
||
31 | protected function beforeInsert(): void |
||
32 | { |
||
33 | $this->addValidator('name') |
||
34 | ->required() |
||
35 | ->latin() |
||
36 | ->callback( |
||
37 | function ($name) { |
||
38 | return !Table::findRowWhere(['name' => $name]); |
||
39 | } |
||
40 | ) |
||
41 | ->setDescription('Role already exists'); |
||
42 | } |
||
43 | |||
44 | /** |
||
45 | * {@inheritdoc} |
||
46 | * |
||
47 | * @throws \Bluz\Validator\Exception\ComponentException |
||
48 | */ |
||
49 | protected function beforeUpdate(): void |
||
71 | ); |
||
72 | } |
||
73 | |||
74 | /** |
||
75 | * isBasic |
||
76 | * |
||
77 | * @return boolean |
||
78 | 1 | */ |
|
79 | public function isBasic(): bool |
||
84 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths