Exception: ActionDispatch::Session::SessionRestoreError
- Inherits:
-
StandardError
- Object
- StandardError
- ActionDispatch::Session::SessionRestoreError
- Defined in:
- lib/action_dispatch/middleware/session/abstract_store.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#initialize(const_error = nil) ⇒ SessionRestoreError
constructor
A new instance of SessionRestoreError.
- #original_exception ⇒ Object
Constructor Details
#initialize(const_error = nil) ⇒ SessionRestoreError
Returns a new instance of SessionRestoreError.
11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/action_dispatch/middleware/session/abstract_store.rb', line 11 def initialize(const_error = nil) if const_error ActiveSupport::Deprecation.warn("Passing #original_exception is deprecated and has no effect. " \ "Exceptions will automatically capture the original exception.", caller) end super("Session contains objects whose class definition isn't available.\n" + "Remember to require the classes for all objects kept in the session.\n" + "(Original exception: #{$!.} [#{$!.class}])\n") set_backtrace $!.backtrace end |
Instance Method Details
#original_exception ⇒ Object
23 24 25 26 |
# File 'lib/action_dispatch/middleware/session/abstract_store.rb', line 23 def original_exception ActiveSupport::Deprecation.warn("#original_exception is deprecated. Use #cause instead.", caller) cause end |