| Conditions | 5 |
| Paths | 3 |
| Total Lines | 11 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | public static function modify(Valable $object, string $name, string $prop) |
||
| 17 | { |
||
| 18 | if ($name === Distance::PROPERTY_MILES && $prop === static::property()) { |
||
| 19 | return $object->$name * static::oneMile(); |
||
| 20 | } |
||
| 21 | |||
| 22 | if ($prop === Distance::PROPERTY_MILES && $name === static::property()) { |
||
| 23 | $object->$prop = $object->$name / static::oneMile(); |
||
| 24 | } |
||
| 25 | |||
| 26 | return null; |
||
| 27 | } |
||
| 30 |