Exception: Aha::Auth::ApiError

Inherits:
Error
  • Object
show all
Defined in:
lib/aha/auth/errors.rb

Overview

Raised for API errors from the server

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, status: nil, body: nil) ⇒ ApiError

Returns a new instance of ApiError.



44
45
46
47
48
# File 'lib/aha/auth/errors.rb', line 44

def initialize(message, status: nil, body: nil)
  super(message)
  @status = status
  @body = body
end

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



42
43
44
# File 'lib/aha/auth/errors.rb', line 42

def body
  @body
end

#statusObject (readonly)

Returns the value of attribute status.



42
43
44
# File 'lib/aha/auth/errors.rb', line 42

def status
  @status
end