Exception: Landable::Error
- Inherits:
-
StandardError
- Object
- StandardError
- Landable::Error
- Defined in:
- lib/landable/error.rb
Direct Known Subclasses
Constant Summary collapse
- STATUS_CODE =
500
Instance Method Summary collapse
-
#initialize(message = nil) ⇒ Error
constructor
A new instance of Error.
- #status_code ⇒ Object
Constructor Details
#initialize(message = nil) ⇒ Error
Returns a new instance of Error.
5 6 7 8 |
# File 'lib/landable/error.rb', line 5 def initialize( = nil) ||= "Status code: #{status_code} (Hint: rescue this in your ApplicationController)" super end |
Instance Method Details
#status_code ⇒ Object
10 11 12 |
# File 'lib/landable/error.rb', line 10 def status_code self.class::STATUS_CODE end |