summaryrefslogtreecommitdiff
path: root/lib/api
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2017-02-08 17:52:36 +0000
committerRémy Coutable <remy@rymai.me>2017-02-08 17:52:36 +0000
commit8d443c0179c6f2b40a894dc69b78f06617172d86 (patch)
tree1206fde7d9f18e3d57976139455948d777c0f6bf /lib/api
parent58a5041a53a0e8df20e075ae494e528d625da1cd (diff)
parent0dacf3c169a85e6f3a1c70f3f5e377d47f770d19 (diff)
downloadgitlab-ce-8d443c0179c6f2b40a894dc69b78f06617172d86.tar.gz
Merge branch 'rename_delete_services' into 'master'
Fix inconsistent naming for services that delete things See merge request !5803
Diffstat (limited to 'lib/api')
-rw-r--r--lib/api/groups.rb2
-rw-r--r--lib/api/notes.rb2
-rw-r--r--lib/api/users.rb2
3 files changed, 3 insertions, 3 deletions
diff --git a/lib/api/groups.rb b/lib/api/groups.rb
index 7682d286866..50dadd94b04 100644
--- a/lib/api/groups.rb
+++ b/lib/api/groups.rb
@@ -125,7 +125,7 @@ module API
delete ":id" do
group = find_group!(params[:id])
authorize! :admin_group, group
- DestroyGroupService.new(group, current_user).execute
+ ::Groups::DestroyService.new(group, current_user).execute
end
desc 'Get a list of projects in this group.' do
diff --git a/lib/api/notes.rb b/lib/api/notes.rb
index 4d2a8f48267..8beccaaabd1 100644
--- a/lib/api/notes.rb
+++ b/lib/api/notes.rb
@@ -131,7 +131,7 @@ module API
note = user_project.notes.find(params[:note_id])
authorize! :admin_note, note
- ::Notes::DeleteService.new(user_project, current_user).execute(note)
+ ::Notes::DestroyService.new(user_project, current_user).execute(note)
present note, with: Entities::Note
end
diff --git a/lib/api/users.rb b/lib/api/users.rb
index 0ed468626b7..4980a90f952 100644
--- a/lib/api/users.rb
+++ b/lib/api/users.rb
@@ -293,7 +293,7 @@ module API
user = User.find_by(id: params[:id])
not_found!('User') unless user
- DeleteUserService.new(current_user).execute(user)
+ ::Users::DestroyService.new(current_user).execute(user)
end
desc 'Block a user. Available only for admins.'