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:
authorGrzegorz Bizon <grzegorz.bizon@ntsn.pl>2016-02-01 13:59:05 +0300
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2016-02-19 19:24:03 +0300
commitc8102d938bf8f1c73058281b2724730c6d88a53b (patch)
tree85d2c7d1ffeead37a1d3869da2a9ca593803fc20 /app/controllers/projects/builds_controller.rb
parent89b181204c9f8d05761463bbf0f5cb1a6be24611 (diff)
Add build eraseable feature implementation
Diffstat (limited to 'app/controllers/projects/builds_controller.rb')
-rw-r--r--app/controllers/projects/builds_controller.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/controllers/projects/builds_controller.rb b/app/controllers/projects/builds_controller.rb
index 3d373e3cc2d..c7c03208c9e 100644
--- a/app/controllers/projects/builds_controller.rb
+++ b/app/controllers/projects/builds_controller.rb
@@ -56,10 +56,10 @@ class Projects::BuildsController < Projects::ApplicationController
render json: @build.to_json(only: [:status, :id, :sha, :coverage], methods: :sha)
end
- def destroy
- @build.destroy
- redirect_to namespace_project_builds_path(project.namespace, project),
- notice: "Build ##{@build.id} has been sucessfully removed!"
+ def erase
+ @build.erase!
+ redirect_to namespace_project_build_path(project.namespace, project, @build),
+ notice: "Build ##{@build.id} has been sucessfully erased!"
end
private