Email validation and other changes