Unverified Commit e740a00e authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets
Browse files

Prevent commit page error if cant collect branches where commit exists


Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 4b219d2a118d
......@@ -12,7 +12,12 @@ def show
return git_not_found! unless @commit
@line_notes = project.notes.for_commit_id(commit.id).inline
@branches = project.repository.branch_names_contains(commit.id)
@branches = begin
project.repository.branch_names_contains(commit.id)
rescue Grit::Git::GitTimeout
[]
end
begin
@suppress_diff = true if commit.diff_suppress? && !params[:force_show_diff]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment