diff options
Diffstat (limited to 'app/controllers/projects/builds_controller.rb')
-rw-r--r-- | app/controllers/projects/builds_controller.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/app/controllers/projects/builds_controller.rb b/app/controllers/projects/builds_controller.rb index 54650bc37a2..8d00f2bf1b2 100644 --- a/app/controllers/projects/builds_controller.rb +++ b/app/controllers/projects/builds_controller.rb @@ -73,8 +73,14 @@ class Projects::BuildsController < Projects::ApplicationController redirect_to build_path(@build) end + # def status + # render json: @build.to_json(only: [:status, :id, :sha, :coverage], methods: :sha) + # end def status - render json: @build.to_json(only: [:status, :id, :sha, :coverage], methods: :sha) + render json: BuildSerializer + .new(project: @project, user: @current_user) + .with_status + .represent(@build) end def erase @@ -91,12 +97,6 @@ class Projects::BuildsController < Projects::ApplicationController end end - def ci_cd_status - render json: BuildSerializer - .new(project: @project, user: @current_user) - .represent(@build) - end - private def build |