summaryrefslogtreecommitdiff
path: root/app/controllers/projects/pipelines_controller.rb
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2016-11-10 21:16:54 +0100
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2016-11-10 21:33:03 +0100
commit6b52adc661896434d3fea1fd7f83c62bef2456a6 (patch)
tree589f9d32eab48cba359c751e940edd92d5d140d3 /app/controllers/projects/pipelines_controller.rb
parentf41c3c02b1c20f7b13013ab135f8d2ff056aea05 (diff)
downloadgitlab-ce-6b52adc661896434d3fea1fd7f83c62bef2456a6.tar.gz
Refine incremental pipeline serializer
Diffstat (limited to 'app/controllers/projects/pipelines_controller.rb')
-rw-r--r--app/controllers/projects/pipelines_controller.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/controllers/projects/pipelines_controller.rb b/app/controllers/projects/pipelines_controller.rb
index 0b3503c6848..62cef8d4a4d 100644
--- a/app/controllers/projects/pipelines_controller.rb
+++ b/app/controllers/projects/pipelines_controller.rb
@@ -17,8 +17,9 @@ class Projects::PipelinesController < Projects::ApplicationController
format.html
format.json do
render json: {
- pipelines: PipelineSerializer.new(project: @project).
- represent(@pipelines, current_user: current_user, last_updated: @last_updated),
+ pipelines: PipelineSerializer
+ .new(project: @project, user: @current_user)
+ .incremental(@pipelines, @last_updated),
updated_at: Time.now,
count: {
all: @pipelines_count,