Exception: Lessonly::Exception

Inherits:
StandardError
  • Object
show all
Defined in:
lib/lessonly/exceptions.rb

Direct Known Subclasses

ResponseError

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, attrs = {}) ⇒ Exception

Returns a new instance of Exception.



5
6
7
8
# File 'lib/lessonly/exceptions.rb', line 5

def initialize(message, attrs = {})
  self.cause = attrs[:cause]
  super(message)
end

Instance Attribute Details

#causeObject

Returns the value of attribute cause.



3
4
5
# File 'lib/lessonly/exceptions.rb', line 3

def cause
  @cause
end