Permalink
Browse files

Fixing possible problem with cents and commas

  • Loading branch information...
1 parent 7f696e6 commit af453e85b11f788662bdbc568af2d90986ea93d1 @samlown samlown committed Dec 14, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/active_merchant/billing/integrations/bbva_tpv/helper.rb
@@ -82,7 +82,7 @@ def amount=(money)
if money.is_a?(String) or cents.to_i <= 0
raise ArgumentError, 'money amount must be either a Money object or a positive integer in cents.'
end
- add_field mappings[:amount], sprintf("%.2f", cents.to_f/100)
+ add_field mappings[:amount], sprintf("%.2f", cents.to_f/100).sub(/\./, ',')
end
def order=(order_id)

0 comments on commit af453e8

Please sign in to comment.