Logs all emails sent from rails to the database.