lib/active_merchant/billing/gateways/linkpoint.rb in activemerchant-1.52.0 vs lib/active_merchant/billing/gateways/linkpoint.rb in activemerchant-1.53.0

- old
+ new

@@ -243,9 +243,20 @@ def credit(money, identification, options = {}) ActiveMerchant.deprecated CREDIT_DEPRECATION_MESSAGE refund(money, identification, options) end + def supports_scrubbing + true + end + + def scrub(transcript) + transcript. + gsub(%r((Authorization: Basic )\w+), '\1[FILTERED]'). + gsub(%r((<cardnumber>)\d+(</cardnumber>))i, '\1[FILTERED]\2'). + gsub(%r((<cvmvalue>)\d+(</cvmvalue>))i, '\1[FILTERED]\2') + end + private # Commit the transaction by posting the XML file to the LinkPoint server def commit(money, creditcard, options = {}) response = parse(ssl_post(test? ? self.test_url : self.live_url, post_data(money, creditcard, options)))