refactored to actual contents of files from treehouse download for new project course: Advanced Social Features in Ruby on Rails