Sha256: 791663583b1150576c5bef41f83f5a85fae5cd7c30c8ce1edc608ad4d5d44e21
Contents?: true
Size: 427 Bytes
Versions: 10
Compression:
Stored size: 427 Bytes
Contents
class Zencoder class Response < Zencoder attr_accessor :code, :body, :raw_body, :raw_response def initialize(options={}) options.each do |k, v| send("#{k}=", v) if respond_to?("#{k}=") end end def success? code.to_i > 199 && code.to_i < 300 end def errors if body.is_a?(Hash) Array(body['errors']).compact else [] end end end end
Version data entries
10 entries across 10 versions & 1 rubygems