diff options
Diffstat (limited to 'app/serializers/stage_entity.rb')
-rw-r--r-- | app/serializers/stage_entity.rb | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/app/serializers/stage_entity.rb b/app/serializers/stage_entity.rb index f278ccfce73..aa570988010 100644 --- a/app/serializers/stage_entity.rb +++ b/app/serializers/stage_entity.rb @@ -13,15 +13,11 @@ class StageEntity < Grape::Entity if: -> (_, opts) { opts[:grouped] }, with: JobGroupEntity - expose :latest_statuses, - if: -> (_, opts) { opts[:details] }, - with: Ci::JobEntity do |stage| + expose :latest_statuses, if: -> (_, opts) { opts[:details] }, with: Ci::JobEntity do |stage| latest_statuses end - expose :retried, - if: -> (_, opts) { opts[:retried] }, - with: Ci::JobEntity do |stage| + expose :retried, if: -> (_, opts) { opts[:retried] }, with: Ci::JobEntity do |stage| retried_statuses end @@ -71,7 +67,7 @@ class StageEntity < Grape::Entity end def preload_metadata(statuses) - Preloaders::CommitStatusPreloader.new(statuses).execute([:metadata]) + Preloaders::CommitStatusPreloader.new(statuses).execute([:metadata, :pipeline]) statuses end |