Class: Shrine::Plugins::Transloadit::ResponseError

Inherits:
Error
  • Object
show all
Defined in:
lib/shrine/plugins/transloadit.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ ResponseError

Returns a new instance of ResponseError.



15
16
17
18
# File 'lib/shrine/plugins/transloadit.rb', line 15

def initialize(response)
  @response = response
  super("#{response["error"]}: #{response["reason"] || response["message"]}")
end

Instance Attribute Details

#responseObject (readonly)

Returns the value of attribute response.



13
14
15
# File 'lib/shrine/plugins/transloadit.rb', line 13

def response
  @response
end