Fixed not sending email bug