Module: ActionController::Rescue
Relationships & Source Files | |
Extension / Inclusion / Inheritance Descendants | |
Included In:
API ,
Base ,
::ActionView::TestCase::TestController ,
Rails::ApplicationController,
::Rails::HealthController ,
Rails::InfoController,
Rails::MailersController,
Rails::PwaController,
Rails::WelcomeController
| |
Super Chains via Extension / Inclusion / Inheritance | |
Class Chain:
self,
::ActiveSupport::Concern
|
|
Instance Chain:
|
|
Defined in: | actionpack/lib/action_controller/metal/rescue.rb |
Overview
This module is responsible for providing [rescue_from](ActiveSupport::Rescuable::ClassMethods#rescue_from) to controllers, wrapping actions to handle configured errors, and configuring when detailed exceptions must be shown.
::ActiveSupport::Rescuable
- Attributes & Methods
Class Method Summary
::ActiveSupport::Concern
- Extended
class_methods | Define class methods from given block. |
included | Evaluate given block in context of base class, so that you can write class macros here. |
prepended | Evaluate given block in context of base class, so that you can write class macros here. |
Instance Attribute Summary
-
#show_detailed_exceptions? ⇒ Boolean
readonly
Override this method if you want to customize when detailed exceptions must be shown.
Instance Method Summary
::ActiveSupport::Rescuable
- Included
#rescue_with_handler | Delegates to the class method, but uses the instance as the subject for rescue_from handlers (method calls, |
Class Attribute Details
.rescue_handlers (rw)
[ GitHub ]# File 'activesupport/lib/active_support/rescuable.rb', line 15
class_attribute :rescue_handlers, default: []
.rescue_handlers? ⇒ Boolean
(rw)
[ GitHub ]
# File 'activesupport/lib/active_support/rescuable.rb', line 15
class_attribute :rescue_handlers, default: []
Instance Attribute Details
#rescue_handlers (rw)
[ GitHub ]# File 'activesupport/lib/active_support/rescuable.rb', line 15
class_attribute :rescue_handlers, default: []
#rescue_handlers? ⇒ Boolean
(rw)
[ GitHub ]
# File 'activesupport/lib/active_support/rescuable.rb', line 15
class_attribute :rescue_handlers, default: []
#show_detailed_exceptions? ⇒ Boolean
(readonly)
Override this method if you want to customize when detailed exceptions must be shown. This method is only called when consider_all_requests_local
is false
. By default, it returns false
, but someone may set it to request.local?
so local requests in production still show the detailed exception pages.
# File 'actionpack/lib/action_controller/metal/rescue.rb', line 21
def show_detailed_exceptions? false end