Added some functionality for viewing projects, refactored some code