add validation for date