Refactor ReposController

move querying logic to responsible models.

Address review comments
Merge pull request #188 from railsaholic/repos_controller_minor_refactor

Refactor ReposController