Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-03-31 21:09:19 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-03-31 21:09:19 +0300
commit676109e1b32682bdbdd94a9ffbd8743784f35521 (patch)
tree71f0394c68455c1736a14c215992de6aa5fe358c /app/models/commit_status.rb
parent5facc34f44ce8736078127a5df174a7b52d922b4 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/commit_status.rb')
-rw-r--r--app/models/commit_status.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/app/models/commit_status.rb b/app/models/commit_status.rb
index 9b08ca3718e..e64380f5d91 100644
--- a/app/models/commit_status.rb
+++ b/app/models/commit_status.rb
@@ -55,6 +55,7 @@ class CommitStatus < ApplicationRecord
scope :for_ref, -> (ref) { where(ref: ref) }
scope :by_name, -> (name) { where(name: name) }
scope :in_pipelines, ->(pipelines) { where(pipeline: pipelines) }
+ scope :eager_load_pipeline, -> { eager_load(:pipeline, project: { namespace: :route }) }
scope :for_project_paths, -> (paths) do
where(project: Project.where_full_path_in(Array(paths)))