lib/active_merchant/billing/gateways/paypal.rb in activemerchant-1.3.1 vs lib/active_merchant/billing/gateways/paypal.rb in activemerchant-1.3.2

- old
+ new

@@ -63,16 +63,16 @@ xml.target! end def add_credit_card(xml, credit_card, address, options) xml.tag! 'n2:CreditCard' do - xml.tag! 'n2:CreditCardType', credit_card_type(credit_card.type) + xml.tag! 'n2:CreditCardType', credit_card_type(card_brand(credit_card)) xml.tag! 'n2:CreditCardNumber', credit_card.number xml.tag! 'n2:ExpMonth', format(credit_card.month, :two_digits) xml.tag! 'n2:ExpYear', format(credit_card.year, :four_digits) xml.tag! 'n2:CVV2', credit_card.verification_value - if [ 'switch', 'solo' ].include?(credit_card.type.to_s) + if [ 'switch', 'solo' ].include?(card_brand(credit_card).to_s) xml.tag! 'n2:StartMonth', format(credit_card.start_month, :two_digits) unless credit_card.start_month.blank? xml.tag! 'n2:StartYear', format(credit_card.start_year, :four_digits) unless credit_card.start_year.blank? xml.tag! 'n2:IssueNumber', format(credit_card.issue_number, :two_digits) unless credit_card.issue_number.blank? end