Refactoring log route
testing email sending