lib/active_merchant/billing/gateways/realex.rb in activemerchant-1.43.3 vs lib/active_merchant/billing/gateways/realex.rb in activemerchant-1.44.0
- old
+ new
@@ -26,11 +26,12 @@
'visa' => 'VISA',
'american_express' => 'AMEX',
'diners_club' => 'DINERS',
'switch' => 'SWITCH',
'solo' => 'SWITCH',
- 'laser' => 'LASER'
+ 'laser' => 'LASER',
+ 'maestro' => 'MC'
}
self.money_format = :cents
self.default_currency = 'EUR'
self.supported_cardtypes = [ :visa, :master, :american_express, :diners_club, :switch, :solo, :laser ]
@@ -71,11 +72,11 @@
request = build_refund_request(money, authorization, options)
commit(request)
end
def credit(money, authorization, options = {})
- deprecated CREDIT_DEPRECATION_MESSAGE
+ ActiveMerchant.deprecated CREDIT_DEPRECATION_MESSAGE
refund(money, authorization, options)
end
def void(authorization, options = {})
request = build_void_request(authorization, options)
@@ -261,19 +262,9 @@
action == :authorization ? '0' : '1'
end
def expiry_date(credit_card)
"#{format(credit_card.month, :two_digits)}#{format(credit_card.year, :two_digits)}"
- end
-
- def normalize(field)
- case field
- when "true" then true
- when "false" then false
- when "" then nil
- when "null" then nil
- else field
- end
end
def message_from(response)
message = nil
case response[:result]