create function to check string for email format