edited comment for gen_email_code function