Sha256: a470e71970963886ad0ee9eb109a3f3d7358210a65460eed8df5145c9035e350

Contents?: true

Size: 390 Bytes

Versions: 2

Compression:

Stored size: 390 Bytes

Contents

module ActiveMerchant #:nodoc:
  module Shipping
    class RateResponse < Response
      attr_reader :rates

      def initialize(success, message, params = {}, options = {})
        @rates = Array(options[:estimates] || options[:rates] || options[:rate_estimates])
        super
      end

      alias_method :estimates, :rates
      alias_method :rate_estimates, :rates
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
active_shipping-0.12.6 lib/active_shipping/shipping/rate_response.rb
active_shipping-0.12.5 lib/active_shipping/shipping/rate_response.rb