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:
authorStan Hu <stanhu@gmail.com>2016-08-06 17:25:51 +0300
committerStan Hu <stanhu@gmail.com>2016-08-10 19:28:21 +0300
commit4955a47cb1c52168114364e45a2fccf6bc105452 (patch)
tree50bb5ea1979a596edef53817aea75796686fc2a9 /lib/api/projects.rb
parentae2d3c417075c83e169ab7662f3dd11e3b2bf043 (diff)
Clean up project destruction
Instead of redirecting from the project service to the service and back to the model, put all destruction code in the service. Also removes a possible source of failure where run_after_commit may not destroy the project.
Diffstat (limited to 'lib/api/projects.rb')
-rw-r--r--lib/api/projects.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/projects.rb b/lib/api/projects.rb
index 8fed7db8803..60cfc103afd 100644
--- a/lib/api/projects.rb
+++ b/lib/api/projects.rb
@@ -323,7 +323,7 @@ module API
# DELETE /projects/:id
delete ":id" do
authorize! :remove_project, user_project
- ::Projects::DestroyService.new(user_project, current_user, {}).pending_delete!
+ ::Projects::DestroyService.new(user_project, current_user, {}).async_execute
end
# Mark this project as forked from another