Corrected the date validator.