diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-08-03 09:08:50 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-08-03 09:08:50 +0300 |
commit | 139f9c7dc18372bc4cdfaab5f887eae5e3547fa5 (patch) | |
tree | 98daa01f7ce13284404b05903326856eb7c35a9c /lib/gitlab/diff/file_collection/base.rb | |
parent | 2c91139c78ce382738c2c5b615cbfba0dd3fed66 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/diff/file_collection/base.rb')
-rw-r--r-- | lib/gitlab/diff/file_collection/base.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/gitlab/diff/file_collection/base.rb b/lib/gitlab/diff/file_collection/base.rb index 6d04c4874c7..f73e060be7f 100644 --- a/lib/gitlab/diff/file_collection/base.rb +++ b/lib/gitlab/diff/file_collection/base.rb @@ -43,10 +43,16 @@ module Gitlab end end + # This is either the new path, otherwise the old path for the diff_file def diff_file_paths diff_files.map(&:file_path) end + # This is both the new and old paths for the diff_file + def diff_paths + diff_files.map(&:paths).flatten.uniq + end + def pagination_data @pagination_data || empty_pagination_data end |