refactored sending email service