summaryrefslogtreecommitdiff
path: root/lib/api/services.rb
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-10-29 18:13:51 +0200
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-10-29 18:13:51 +0200
commitee0e9830c1c1e4c54fd0b18fadef50f76c3680a4 (patch)
treedfb632a27cf46d86e255882872095d2b1a8d41a6 /lib/api/services.rb
parent0b57c118fc63be9169815b302b58886a0688dd82 (diff)
downloadgitlab-ce-ee0e9830c1c1e4c54fd0b18fadef50f76c3680a4.tar.gz
gitlab-ci service api: clean values instead of destroy
Diffstat (limited to 'lib/api/services.rb')
-rw-r--r--lib/api/services.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/api/services.rb b/lib/api/services.rb
index d562b9484c5..bde502e32e1 100644
--- a/lib/api/services.rb
+++ b/lib/api/services.rb
@@ -31,7 +31,11 @@ module API
# DELETE /projects/:id/keys/:id
delete ":id/services/gitlab-ci" do
if user_project.gitlab_ci_service
- user_project.gitlab_ci_service.destroy
+ user_project.gitlab_ci_service.update_attributes(
+ active: false,
+ token: nil,
+ project_url: nil
+ )
end
end
end