Sha256: f0174d4d9a81262768573c8488f07f7cf6f3e9ff5621ffb79c03f2b7642b426a
Contents?: true
Size: 446 Bytes
Versions: 2
Compression:
Stored size: 446 Bytes
Contents
module IqSMS class Response attr_reader :original_response, :hash, :status def initialize(original_response) @original_response = original_response @hash = if @original_response.body.present? JSON.parse(@original_response.body) else {} end @hash = IqSMS::Utils.deeply_with_indifferent_access(@hash) @status = RequestStatus.new(@hash[:status], @hash[:description]) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
iqsms-0.2.1 | lib/iqsms/response.rb |
iqsms-0.2.0 | lib/iqsms/response.rb |