Exception: MuaraiCaptcha::ApiError
- Defined in:
- lib/muaraicaptcha.rb
Overview
Raised when the API returns a non-zero errorId.
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#description ⇒ Object
readonly
Returns the value of attribute description.
Instance Method Summary collapse
-
#initialize(code, description) ⇒ ApiError
constructor
A new instance of ApiError.
Constructor Details
#initialize(code, description) ⇒ ApiError
Returns a new instance of ApiError.
30 31 32 33 34 |
# File 'lib/muaraicaptcha.rb', line 30 def initialize(code, description) @code = code @description = description super("#{code}: #{description}") end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
28 29 30 |
# File 'lib/muaraicaptcha.rb', line 28 def code @code end |
#description ⇒ Object (readonly)
Returns the value of attribute description.
28 29 30 |
# File 'lib/muaraicaptcha.rb', line 28 def description @description end |