improving emails and add logs to track in heroku