src/GraphQL/Resolvers/ApplyVersionFilters.php
protected function isValidDate($date)
    {
        $dt = DateTime::createFromFormat('Y-m-d', $date);

        return ($dt !== false && !array_sum($dt->getLastErrors()));
    }
protected function isValidDate($date)
    {
        $dt = DateTime::createFromFormat('Y-m-d', $date);

        return ($dt !== false && !array_sum($dt->getLastErrors()));
    }
protected function isValidDate ( $ date ) { $ dt = DateTime :: createFromFormat ( 'Y-m-d' , $ date ) ; return ( $ dt !== false && ! array_sum ( $ dt -> getLastErrors ( ) ) ) ; }
Returns true if date is in proper YYYY-MM-DD format
@param string $date
@return bool
Returns true if date is in proper YYYY - MM - DD format