| Conditions | 2 |
| Paths | 2 |
| Total Lines | 12 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 22 | public function filter($value) |
||
| 23 | { |
||
| 24 | try { |
||
| 25 | $result = $this->normalizeDateTime($value); |
||
| 26 | } catch (\Exception $e) { |
||
| 27 | // DateTime threw an exception, an invalid date string was provided |
||
| 28 | //just return original input - this is what other filters do |
||
| 29 | return $value; |
||
| 30 | } |
||
| 31 | |||
| 32 | return $result; |
||
| 33 | } |
||
| 34 | |||
| 54 |