diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-03 18:07:07 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-03 18:07:07 +0300 |
commit | 9a1c5456747a7b5b218b8b44e4b43396bf7fd705 (patch) | |
tree | dc5873f33437c897389e923a59365fb192d87fb8 /app/services/concerns/git | |
parent | 927cfbfe63dd3dc64df9d341d7c4328a2fe3597f (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/services/concerns/git')
-rw-r--r-- | app/services/concerns/git/change_params.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/app/services/concerns/git/change_params.rb b/app/services/concerns/git/change_params.rb new file mode 100644 index 00000000000..32faf805b5e --- /dev/null +++ b/app/services/concerns/git/change_params.rb @@ -0,0 +1,17 @@ +# frozen_string_literal: true + +module Git + module ChangeParams + private + + %i[oldrev newrev ref].each do |method| + define_method method do + change[method] + end + end + + def change + @change ||= params.fetch(:change, {}) + end + end +end |