| Conditions | 3 |
| Paths | 3 |
| Total Lines | 11 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 3 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 33 | 7 | public function validate($value, Constraint $constraint) |
|
| 34 | { |
||
| 35 | 7 | if ($value instanceof PhoneNumber) { |
|
| 36 | 3 | if ($value->hasRawInput()) { |
|
| 37 | 3 | $value = $value->getRawInput(); |
|
| 38 | } else { |
||
| 39 | 2 | $value = $value->getNationalNumber(); |
|
| 40 | } |
||
| 41 | } |
||
| 42 | |||
| 43 | 7 | parent::validate($value, $constraint); |
|
| 44 | 7 | } |
|
| 46 |