Fix to send emails