lib/active_merchant/billing/gateways/allied_wallet.rb in activemerchant-1.114.0 vs lib/active_merchant/billing/gateways/allied_wallet.rb in activemerchant-1.116.0
- old
+ new
@@ -10,59 +10,59 @@
self.default_currency = 'USD'
self.money_format = :dollars
self.supported_cardtypes = %i[visa master american_express discover
diners_club jcb maestro]
- def initialize(options={})
+ def initialize(options = {})
requires!(options, :site_id, :merchant_id, :token)
super
end
- def purchase(amount, payment_method, options={})
+ def purchase(amount, payment_method, options = {})
post = {}
add_invoice(post, amount, options)
add_payment_method(post, payment_method)
add_customer_data(post, options)
commit(:purchase, post)
end
- def authorize(amount, payment_method, options={})
+ def authorize(amount, payment_method, options = {})
post = {}
add_invoice(post, amount, options)
add_payment_method(post, payment_method)
add_customer_data(post, options)
commit(:authorize, post)
end
- def capture(amount, authorization, options={})
+ def capture(amount, authorization, options = {})
post = {}
add_invoice(post, amount, options)
add_reference(post, authorization, :capture)
add_customer_data(post, options)
commit(:capture, post)
end
- def void(authorization, options={})
+ def void(authorization, options = {})
post = {}
add_reference(post, authorization, :void)
commit(:void, post)
end
- def refund(amount, authorization, options={})
+ def refund(amount, authorization, options = {})
post = {}
add_invoice(post, amount, options)
add_reference(post, authorization, :refund)
add_amount(post, amount)
add_customer_data(post, options)
commit(:refund, post)
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