Total Complexity | 3 |
Total Lines | 27 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
10 | class TranslationUpdateRequest extends BaseFormRequest |
||
11 | { |
||
12 | protected function getEndpointName(): string |
||
13 | { |
||
14 | return 'translations.update'; |
||
15 | } |
||
16 | |||
17 | public function rules(): array |
||
18 | { |
||
19 | return [ |
||
20 | 'key' => [ |
||
21 | 'nullable', |
||
22 | 'string', |
||
23 | Rule::unique((new Translation())->getTable(), 'code') |
||
24 | ->whereNot('key', $this->getTranslation()->key), |
||
25 | ], |
||
26 | 'label' => 'required|string', |
||
27 | 'translations' => [ |
||
28 | 'required', |
||
29 | app(TranslationValuesRule::class), |
||
30 | ], |
||
31 | ]; |
||
32 | } |
||
33 | |||
34 | public function getTranslation(): Translation |
||
37 | } |
||
38 | } |
||
39 |
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