8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 27c41f1 commit f3408ccCopy full SHA for f3408cc
src/Symfony/Component/Finder/Comparator/DateComparator.php
@@ -32,7 +32,10 @@ public function __construct($test)
32
throw new \InvalidArgumentException(sprintf('Don\'t understand "%s" as a date test.', $test));
33
}
34
35
- if (false === $target = @strtotime($matches[2])) {
+ try {
36
+ $date = new \DateTime($matches[2]);
37
+ $target = $date->format('U');
38
+ } catch (\Exception $e) {
39
throw new \InvalidArgumentException(sprintf('"%s" is not a valid date.', $matches[2]));
40
41
0 commit comments