added date validation

added date validation
fixed documentation

fixed documentation