added email validation
moved config to yml file