lib/pagarme/transaction.rb in pagarme-0.12 vs lib/pagarme/transaction.rb in pagarme-0.13
- old
+ new
@@ -30,10 +30,10 @@
self.card_number = first_parameter[:card_number]
self.card_holder_name = first_parameter[:card_holder_name]
self.card_expiracy_month = first_parameter[:card_expiracy_month]
self.card_expiracy_year = first_parameter[:card_expiracy_year]
self.card_cvv = first_parameter[:card_cvv]
- self.installments = first_parameter[:installments]
+ self.installments = first_parameter[:installments] if first_parameter[:installments]
self.live = first_parameter[:live]
self.live = PagarMe.live unless self.live
end
update_fields_from_response(server_response) if server_response