diff options
Diffstat (limited to 'app/workers/stuck_merge_jobs_worker.rb')
-rw-r--r-- | app/workers/stuck_merge_jobs_worker.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/workers/stuck_merge_jobs_worker.rb b/app/workers/stuck_merge_jobs_worker.rb index e840ae47421..024863ab530 100644 --- a/app/workers/stuck_merge_jobs_worker.rb +++ b/app/workers/stuck_merge_jobs_worker.rb @@ -4,6 +4,8 @@ class StuckMergeJobsWorker include ApplicationWorker include CronjobQueue + feature_category :source_code_management + def self.logger Rails.logger # rubocop:disable Gitlab/RailsLogger end @@ -31,7 +33,7 @@ class StuckMergeJobsWorker def apply_current_state!(completed_jids, completed_ids) merge_requests = MergeRequest.where(id: completed_ids) - merge_requests.where.not(merge_commit_sha: nil).update_all(state: :merged) + merge_requests.where.not(merge_commit_sha: nil).update_all(state_id: MergeRequest.available_states[:merged]) merge_requests_to_reopen = merge_requests.where(merge_commit_sha: nil) |