From e80d7a804f335447c8c4db8d8de3532957d80ec8 Mon Sep 17 00:00:00 2001 From: Stan Hu Date: Mon, 22 Jun 2015 15:08:02 -0700 Subject: Fix error when deleting a user who has projects Closes #1856 Closes https://github.com/gitlabhq/gitlabhq/issues/9394 --- lib/api/users.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/api') diff --git a/lib/api/users.rb b/lib/api/users.rb index 7d4c68c7412..9b268cfe8bc 100644 --- a/lib/api/users.rb +++ b/lib/api/users.rb @@ -194,7 +194,7 @@ module API user = User.find_by(id: params[:id]) if user - DeleteUserService.new.execute(user) + DeleteUserService.new(current_user).execute(user) else not_found!('User') end -- cgit v1.2.1