Exception: VoximplantApi::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/voximplant_api/client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(error) ⇒ Error

Returns a new instance of Error.



9
10
11
12
# File 'lib/voximplant_api/client.rb', line 9

def initialize(error)
  super error["msg"]
  @code = error["code"]
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



7
8
9
# File 'lib/voximplant_api/client.rb', line 7

def code
  @code
end