| Conditions | 5 |
| Paths | 4 |
| Total Lines | 23 |
| Code Lines | 13 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 16 | * @return void |
||
| 17 | */ |
||
| 18 | public function validate(string $attribute, mixed $value, Closure $fail): void |
||
| 19 | { |
||
| 20 | if (! $this->isImeiValid($value)) { |
||
| 21 | |||
| 22 | $fail('validate.imei')->translate(); |
||
| 23 | } |
||
| 24 | } |
||
| 25 | |||
| 26 | /** |
||
| 27 | * Check if IMEI is valid |
||
| 28 | * |
||
| 29 | * @param mixed $value |
||
| 30 | * @return bool |
||
| 31 | */ |
||
| 32 | private function isImeiValid(mixed $value): bool |
||
| 33 | { |
||
| 34 | $imei = $value; |
||
| 35 | |||
| 36 | if (strlen($imei) != 15 || ! ctype_digit($imei)) { |
||
| 37 | return false; |
||
| 38 | } |
||
| 39 | |||
| 57 |
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