Sha256: abfec2d2ee95365614808718e181143245ea93f7dc0ac3c712fb86c7efef686d

Contents?: true

Size: 304 Bytes

Versions: 6

Compression:

Stored size: 304 Bytes

Contents

module Channable
  class Response

    attr_reader :data
    attr_reader :success
    attr_reader :response

    def initialize(response_data)
      @response = response_data
      @success = response_data.success?
      @data = JSON.parse(response_data.body, object_class: OpenStruct)
    end

  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
spree_channable-0.0.24 lib/channable/response.rb
spree_channable-0.0.23 lib/channable/response.rb
spree_channable-0.0.22 lib/channable/response.rb
spree_channable-0.0.21 lib/channable/response.rb
spree_channable-0.0.20 lib/channable/response.rb
spree_channable-0.0.18.alpha lib/channable/response.rb