now correctly sending emails