diff --git a/app/controllers/error_controller.rb b/app/controllers/error_controller.rb index 491dccc971..abdf11f264 100644 --- a/app/controllers/error_controller.rb +++ b/app/controllers/error_controller.rb @@ -2,8 +2,12 @@ class ErrorController < ApplicationController skip_before_action :authenticate_user! + skip_after_action :verify_authorized def index + end + + def create raise StandardError.new "This is an intentional test exception" end end diff --git a/app/views/error/index.html.erb b/app/views/error/index.html.erb index 13254f3cae..769a97ca15 100644 --- a/app/views/error/index.html.erb +++ b/app/views/error/index.html.erb @@ -1,6 +1,7 @@
If you are the application owner check the logs for more information.
+Click the button below to trigger an intentional test exception.
+ <%= button_to "Trigger Exception", error_path, method: :post, class: "btn btn-danger", data: { turbo: false } %>