diff options
author | Valeriy Sizov <vsv2711@gmail.com> | 2012-10-17 23:59:42 +0300 |
---|---|---|
committer | Valeriy Sizov <vsv2711@gmail.com> | 2012-10-17 23:59:42 +0300 |
commit | 883d138f15610a831ec8f5bf9d9ec640b6df140d (patch) | |
tree | e56b965febbe18623143323d0aa788b082a14279 /lib | |
parent | db469ea3e69f03f5c1966958041bca91a04686ce (diff) | |
download | gitlab-ce-883d138f15610a831ec8f5bf9d9ec640b6df140d.tar.gz |
Fix 500 error when project is empty
Diffstat (limited to 'lib')
-rw-r--r-- | lib/gitlab/markdown.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/markdown.rb b/lib/gitlab/markdown.rb index ba993abf7f7..fab89d09896 100644 --- a/lib/gitlab/markdown.rb +++ b/lib/gitlab/markdown.rb @@ -173,7 +173,7 @@ module Gitlab end def reference_commit(identifier) - if commit = @project.commit(identifier) + if @project.valid_repo? && commit = @project.commit(identifier) link_to(identifier, project_commit_path(@project, commit), html_options.merge(title: CommitDecorator.new(commit).link_title, class: "gfm gfm-commit #{html_options[:class]}")) end end |