Applied best practices on the email handling