better error handling for not found resource, gitolite error

This commit is contained in:
Dmitriy Zaporozhets 2012-02-22 07:14:54 +02:00
parent 9e6d0710e9
commit 7d279f9302
9 changed files with 73 additions and 7 deletions

View file

@ -26,6 +26,9 @@ class CommitsController < ApplicationController
def show
@commit = project.commit(params[:id])
git_not_found! and return unless @commit
@notes = project.commit_notes(@commit).fresh.limit(20)
@note = @project.build_commit_note(@commit)