| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 19 | public function transform(array $values) |
||
| 20 | { |
||
| 21 | 1 | $this->validate($values); |
|
| 22 | |||
| 23 | 1 | $dtStart = \DateTime::createFromFormat('Ymd\THis', $values[1], new \DateTimeZone($values[0])); |
|
| 24 | |||
| 25 | 1 | if (!$dtStart) { |
|
|
|
|||
| 26 | 1 | throw new InvalidRruleException(DtStartTimezonedExtractor::RRULE_PARAMETER, implode(', ', $values)); |
|
| 27 | } |
||
| 28 | |||
| 29 | 1 | return $dtStart; |
|
| 30 | } |
||
| 49 |