Some flow cleanup and adding mailer