moved mailer.js back to models folder