summaryrefslogtreecommitdiff
path: root/app/controllers
diff options
context:
space:
mode:
authorZeger-Jan van de Weg <zegerjan@gitlab.com>2016-03-17 11:13:16 +0100
committerZeger-Jan van de Weg <zegerjan@gitlab.com>2016-03-17 11:13:16 +0100
commit481e73fb76bbdc845ba6899682ab5fa8c05b11bc (patch)
tree70becb0067bba3e9f529e81a3bca9608408929a9 /app/controllers
parent48274581551b73575149463be0c050f6b5a564ee (diff)
parent4171933c0963696626c879c2d05afa1594a71d99 (diff)
downloadgitlab-ce-481e73fb76bbdc845ba6899682ab5fa8c05b11bc.tar.gz
Merge branch 'master' into new-branch-button-issue
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/admin/abuse_reports_controller.rb2
-rw-r--r--app/controllers/admin/users_controller.rb4
2 files changed, 3 insertions, 3 deletions
diff --git a/app/controllers/admin/abuse_reports_controller.rb b/app/controllers/admin/abuse_reports_controller.rb
index 2463cfa87be..e9b0972bdd8 100644
--- a/app/controllers/admin/abuse_reports_controller.rb
+++ b/app/controllers/admin/abuse_reports_controller.rb
@@ -6,7 +6,7 @@ class Admin::AbuseReportsController < Admin::ApplicationController
def destroy
abuse_report = AbuseReport.find(params[:id])
- abuse_report.remove_user if params[:remove_user]
+ abuse_report.remove_user(deleted_by: current_user) if params[:remove_user]
abuse_report.destroy
render nothing: true
diff --git a/app/controllers/admin/users_controller.rb b/app/controllers/admin/users_controller.rb
index 87f4fb455b8..3063d299b1a 100644
--- a/app/controllers/admin/users_controller.rb
+++ b/app/controllers/admin/users_controller.rb
@@ -119,10 +119,10 @@ class Admin::UsersController < Admin::ApplicationController
end
def destroy
- DeleteUserService.new(current_user).execute(user)
+ DeleteUserWorker.perform_async(current_user.id, user.id)
respond_to do |format|
- format.html { redirect_to admin_users_path }
+ format.html { redirect_to admin_users_path, notice: "The user is being deleted." }
format.json { head :ok }
end
end