Exception: FacebookTopics::ApiError
- Inherits:
-
RuntimeError
- Object
- RuntimeError
- FacebookTopics::ApiError
- Defined in:
- lib/facebook_topics/error.rb
Instance Attribute Summary collapse
-
#code ⇒ Object
Returns the value of attribute code.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(err) ⇒ ApiError
constructor
A new instance of ApiError.
Constructor Details
#initialize(err) ⇒ ApiError
Returns a new instance of ApiError.
5 6 7 8 9 10 |
# File 'lib/facebook_topics/error.rb', line 5 def initialize(err) @code = err["code"] @type = err["type"] super("#{@type} #{err['message']} - code: #{@code}") end |
Instance Attribute Details
#code ⇒ Object
Returns the value of attribute code.
3 4 5 |
# File 'lib/facebook_topics/error.rb', line 3 def code @code end |
#type ⇒ Object
Returns the value of attribute type.
3 4 5 |
# File 'lib/facebook_topics/error.rb', line 3 def type @type end |