lib/active_merchant/billing/gateways/pro_pay.rb in activemerchant-1.114.0 vs lib/active_merchant/billing/gateways/pro_pay.rb in activemerchant-1.116.0
- old
+ new
@@ -131,16 +131,16 @@
'97' => 'Approved for a lesser amount. ProPay will not settle and consider this a decline.',
'98' => 'Failure HV',
'99' => 'Generic decline or unable to parse issuer response code'
}
- def initialize(options={})
+ def initialize(options = {})
requires!(options, :cert_str)
super
end
- def purchase(money, payment, options={})
+ def purchase(money, payment, options = {})
request = build_xml_request do |xml|
add_invoice(xml, money, options)
add_payment(xml, payment, options)
add_address(xml, options)
add_account(xml, options)
@@ -149,11 +149,11 @@
end
commit(request)
end
- def authorize(money, payment, options={})
+ def authorize(money, payment, options = {})
request = build_xml_request do |xml|
add_invoice(xml, money, options)
add_payment(xml, payment, options)
add_address(xml, options)
add_account(xml, options)
@@ -162,47 +162,47 @@
end
commit(request)
end
- def capture(money, authorization, options={})
+ def capture(money, authorization, options = {})
request = build_xml_request do |xml|
add_invoice(xml, money, options)
add_account(xml, options)
xml.transNum authorization
xml.transType '06'
end
commit(request)
end
- def refund(money, authorization, options={})
+ def refund(money, authorization, options = {})
request = build_xml_request do |xml|
add_invoice(xml, money, options)
add_account(xml, options)
xml.transNum authorization
xml.transType '07'
end
commit(request)
end
- def void(authorization, options={})
+ def void(authorization, options = {})
refund(nil, authorization, options)
end
- def credit(money, payment, options={})
+ def credit(money, payment, options = {})
request = build_xml_request do |xml|
add_invoice(xml, money, options)
add_payment(xml, payment, options)
add_account(xml, options)
xml.transType '35'
end
commit(request)
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