added email validation.