| Conditions | 2 |
| Paths | 2 |
| Total Lines | 8 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 17 | 5 | public function validate(mixed $value, object $rule, ValidatorInterface $validator, ?ValidationContext $context = null): Result |
|
| 18 | { |
||
| 19 | 5 | $result = new Result(); |
|
| 20 | 5 | if (!$validator->validate($value, $rule->getRuleSet())->isValid()) { |
|
| 21 | 4 | $result->addError($rule->message); |
|
| 22 | } |
||
| 23 | |||
| 24 | 5 | return $result; |
|
| 25 | } |
||
| 27 |