diff options
Diffstat (limited to 'app/presenters/gitlab/blame_presenter.rb')
-rw-r--r-- | app/presenters/gitlab/blame_presenter.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/app/presenters/gitlab/blame_presenter.rb b/app/presenters/gitlab/blame_presenter.rb index 6230e61d2be..0a2738bea5f 100644 --- a/app/presenters/gitlab/blame_presenter.rb +++ b/app/presenters/gitlab/blame_presenter.rb @@ -40,6 +40,10 @@ module Gitlab @commits[commit.id] ||= get_commit_data(commit, previous_path) end + def groups_commit_data + groups.each { |group| group[:commit_data] = commit_data(group[:commit]) } + end + private # Huge source files with a high churn rate (e.g. 'locale/gitlab.pot') could have @@ -86,5 +90,17 @@ module Gitlab def mail_to(*args, &block) ActionController::Base.helpers.mail_to(*args, &block) end + + def project + return super.project if defined?(super.project) + + blame.commit.repository.project + end + + def page + return super.page if defined?(super.page) + + nil + end end end |