fix error when only one app is present

It fixes ActionView::Template::Error (undefined method `>' for nil:NilClass)
error. This error was showing when there is only one app was present.
In AppsController when we were trying to sort our apps and if apps.count == 1
the sort method actually doesn't call block so we had empty
@unresolved_counts, @problem_counts assigns.
Merge pull request #194 from nashby/sort-by-unresolved-errors

fix error when only one app is present
Separate count caching and sorting to simplify code in AppsController#collection.
Fixed sorting for Apps index table
Use nonzero? to chain sorting rules.
Rescue all exceptions during create_issue and display error message in flash[:error]
Refactored issues. If a user links their GitHub account, they can now choose between creating an issue on Github, or on their configured issue tracker.
extract comments logic to CommentsController
Merge pull request #195 from errbit/comments-controller

extract comments logic to CommentsController
Only expand title bar for errs#show page
Added GitHub authentication info to README. Replaced numbers with bullets, since they always reset.
Added issue_type to problems, to record which issue tracker the link belongs to (in case tracker is changed, or multiple trackers are registered)
Use `.label` method instead of `.class::Label` for retrieving issue tracker labels
Remove ugly Sign in with Github button from README [ci skip]
Allow configuration of GitHub permissions (turn on/off access to creating GitHub issues for public/private/no repos)
Change authentication sub-headings to h3.
Add newline to README [ci skip]
remove unnecessary actions
render with implicit partial param
remove blank omiauth initializer