From 9625affcd020972d7869420c2673ee5f2939fc8d Mon Sep 17 00:00:00 2001 From: Piet Schijven Date: Wed, 19 Jun 2024 16:26:58 +0200 Subject: [PATCH] Provided callback in ControllerExtensions, such that one can send a BadRequest to Sentry too. --- app/controllers/concerns/controller_extensions.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/controllers/concerns/controller_extensions.rb b/app/controllers/concerns/controller_extensions.rb index 0f4cfe894..bd8401188 100644 --- a/app/controllers/concerns/controller_extensions.rb +++ b/app/controllers/concerns/controller_extensions.rb @@ -16,6 +16,7 @@ module ControllerExtensions rescue_from CanCan::AccessDenied, with: :handle_access_denied rescue_from ActionController::ParameterMissing, with: :handle_bad_request rescue_from ActionController::UnknownFormat, with: :handle_unknown_format + rescue_from ActionController::BadRequest, with: :handle_bad_request end protected