diff options
Diffstat (limited to 'app/controllers/abuse_reports_controller.rb')
-rw-r--r-- | app/controllers/abuse_reports_controller.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/controllers/abuse_reports_controller.rb b/app/controllers/abuse_reports_controller.rb index 9d1c68eea89..206a5b11e4b 100644 --- a/app/controllers/abuse_reports_controller.rb +++ b/app/controllers/abuse_reports_controller.rb @@ -20,8 +20,10 @@ class AbuseReportsController < ApplicationController message = _("Thank you for your report. A GitLab administrator will look into it shortly.") redirect_to root_path, notice: message - else + elsif report_params[:user_id].present? render :new + else + redirect_to root_path, alert: _("Cannot create the abuse report. The reported user was invalid. Please try again or contact support.") end end |