Refactoring and Bug Fixes

- Tidied up classes and added additional comments
- Fixed bug where email .csv was not sending correctly