summaryrefslogtreecommitdiff
path: root/app/models/merge_request.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-11-19 09:06:16 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2019-11-19 09:06:16 +0000
commit34b3567c97ecc0f317adae04e10e4d7d8c8830db (patch)
tree2612572041a8a6121ce9098cabf8724e67a96ea2 /app/models/merge_request.rb
parent3209c1a49c14cab93eb347bfca59bace30879440 (diff)
downloadgitlab-ce-34b3567c97ecc0f317adae04e10e4d7d8c8830db.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/merge_request.rb')
-rw-r--r--app/models/merge_request.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/app/models/merge_request.rb b/app/models/merge_request.rb
index 7e1898e7142..a8c15ef2028 100644
--- a/app/models/merge_request.rb
+++ b/app/models/merge_request.rb
@@ -241,6 +241,9 @@ class MergeRequest < ApplicationRecord
alias_attribute :auto_merge_enabled, :merge_when_pipeline_succeeds
alias_method :issuing_parent, :target_project
+ delegate :active?, to: :head_pipeline, prefix: true, allow_nil: true
+ delegate :success?, to: :actual_head_pipeline, prefix: true, allow_nil: true
+
RebaseLockTimeout = Class.new(StandardError)
REBASE_LOCK_MESSAGE = _("Failed to enqueue the rebase operation, possibly due to a long-lived transaction. Try again later.")