refactored user model, homepage controller and nav bar controller to place  in appropriate place, plus add semi colons