Fixed app sending email twice