lib/active_merchant/billing/gateway.rb in activemerchant-1.86.0 vs lib/active_merchant/billing/gateway.rb in activemerchant-1.87.0
- old
+ new
@@ -202,15 +202,15 @@
protected # :nodoc: all
def normalize(field)
case field
- when 'true' then true
- when 'false' then false
- when '' then nil
- when 'null' then nil
- else field
+ when 'true' then true
+ when 'false' then false
+ when '' then nil
+ when 'null' then nil
+ else field
end
end
def user_agent
@@ua ||= JSON.dump({
@@ -239,13 +239,13 @@
end
def amount(money)
return nil if money.nil?
cents = if money.respond_to?(:cents)
- ActiveMerchant.deprecated 'Support for Money objects is deprecated and will be removed from a future release of ActiveMerchant. Please use an Integer value in cents'
- money.cents
- else
- money
+ ActiveMerchant.deprecated 'Support for Money objects is deprecated and will be removed from a future release of ActiveMerchant. Please use an Integer value in cents'
+ money.cents
+ else
+ money
end
if money.is_a?(String)
raise ArgumentError, 'money amount must be a positive Integer in cents.'
end