lib/active_merchant/billing/gateways/axcessms.rb in activemerchant-1.114.0 vs lib/active_merchant/billing/gateways/axcessms.rb in activemerchant-1.116.0

- old
+ new

@@ -21,37 +21,37 @@ PAYMENT_CODE_CAPTURE = 'CC.CP' PAYMENT_CODE_REVERSAL = 'CC.RV' PAYMENT_CODE_REFUND = 'CC.RF' PAYMENT_CODE_REBILL = 'CC.RB' - def initialize(options={}) + def initialize(options = {}) requires!(options, :sender, :login, :password, :channel) super end - def purchase(money, payment, options={}) + def purchase(money, payment, options = {}) payment_code = payment.respond_to?(:number) ? PAYMENT_CODE_DEBIT : PAYMENT_CODE_REBILL commit(payment_code, money, payment, options) end - def authorize(money, authorization, options={}) + def authorize(money, authorization, options = {}) commit(PAYMENT_CODE_PREAUTHORIZATION, money, authorization, options) end - def capture(money, authorization, options={}) + def capture(money, authorization, options = {}) commit(PAYMENT_CODE_CAPTURE, money, authorization, options) end - def refund(money, authorization, options={}) + def refund(money, authorization, options = {}) commit(PAYMENT_CODE_REFUND, money, authorization, options) end - def void(authorization, options={}) + def void(authorization, options = {}) commit(PAYMENT_CODE_REVERSAL, nil, authorization, options) end - def verify(credit_card, options={}) + def verify(credit_card, options = {}) MultiResponse.run(:use_first_response) do |r| r.process { authorize(100, credit_card, options) } r.process(:ignore_result) { void(r.authorization, options) } end end @@ -71,11 +71,10 @@ message = "#{response[:reason]} - #{response[:return]}" authorization = response[:unique_id] Response.new(success, message, response, authorization: authorization, - test: (response[:mode] != 'LIVE') - ) + test: (response[:mode] != 'LIVE')) end def parse(body) return {} if body.blank?