diff options
Diffstat (limited to 'app/models/ci/build.rb')
-rw-r--r-- | app/models/ci/build.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/app/models/ci/build.rb b/app/models/ci/build.rb index e95e2c538c5..d61f0bbfb10 100644 --- a/app/models/ci/build.rb +++ b/app/models/ci/build.rb @@ -173,8 +173,10 @@ module Ci scope :queued_before, ->(time) { where(arel_table[:queued_at].lt(time)) } scope :order_id_desc, -> { order('ci_builds.id DESC') } - PROJECT_ROUTE_AND_NAMESPACE_ROUTE = { project: [:project_feature, :route, { namespace: :route }] }.freeze - scope :preload_project_and_pipeline_project, -> { preload(PROJECT_ROUTE_AND_NAMESPACE_ROUTE, pipeline: PROJECT_ROUTE_AND_NAMESPACE_ROUTE) } + scope :preload_project_and_pipeline_project, -> do + preload(Ci::Pipeline::PROJECT_ROUTE_AND_NAMESPACE_ROUTE, + pipeline: Ci::Pipeline::PROJECT_ROUTE_AND_NAMESPACE_ROUTE) + end acts_as_taggable |