diff --git a/classes/wc-gateway-paypal-pro-payflow-angelleye.php b/classes/wc-gateway-paypal-pro-payflow-angelleye.php
index 33e4dc9ac..ba388100b 100644
--- a/classes/wc-gateway-paypal-pro-payflow-angelleye.php
+++ b/classes/wc-gateway-paypal-pro-payflow-angelleye.php
@@ -1425,11 +1425,25 @@ public function process_subscription_payment($order, $amount, $payment_token = n
*/
$avs_address_response_code = isset($PayPalResult['AVSADDR']) ? $PayPalResult['AVSADDR'] : '';
$avs_zip_response_code = isset($PayPalResult['AVSZIP']) ? $PayPalResult['AVSZIP'] : '';
+ $proc_avs_response_code = isset($PayPalResult['PROCAVS']) ? $PayPalResult['PROCAVS'] : '';
$avs_response_order_note = __('Address Verification Result', 'paypal-for-woocommerce');
- $avs_response_order_note .= "\n";
- $avs_response_order_note .= sprintf(__('Address Match: %s', 'paypal-for-woocommerce'), $avs_address_response_code);
- $avs_response_order_note .= "\n";
- $avs_response_order_note .= sprintf(__('Postal Match: %s', 'paypal-for-woocommerce'), $avs_zip_response_code);
+ $avs_response_order_note .= '
';
+ $avs_response_order_note .= '- ' . sprintf(__('AVS: %s', 'paypal-for-woocommerce'), $proc_avs_response_code) . '
';
+ $avs_response_order_note .= '';
+ $avs_response_order_note .= '- ' . sprintf(__('Address Match: %s', 'paypal-for-woocommerce'), $avs_address_response_code) . '
';
+ $avs_response_order_note .= '- ' . sprintf(__('Postal Match: %s', 'paypal-for-woocommerce'), $avs_zip_response_code) . '
';
+ $avs_response_order_note .= "";
+ $avs_response_order_note .= '
';
+ $old_wc = version_compare(WC_VERSION, '3.0', '<');
+ if ($old_wc) {
+ update_post_meta($order_id, '_AVSADDR', $avs_address_response_code);
+ update_post_meta($order_id, '_AVSZIP', $avs_zip_response_code);
+ update_post_meta($order_id, '_PROCAVS', $avs_zip_response_code);
+ } else {
+ update_post_meta($order->get_id(), '_AVSADDR', $avs_address_response_code);
+ update_post_meta($order->get_id(), '_AVSZIP', $avs_zip_response_code);
+ update_post_meta($order->get_id(), '_PROCAVS', $avs_zip_response_code);
+ }
$order->add_order_note($avs_response_order_note);
/**
* Add order notes for CVV2 result
diff --git a/readme.txt b/readme.txt
index 0e3c77879..4a96e51de 100644
--- a/readme.txt
+++ b/readme.txt
@@ -136,6 +136,7 @@ Automatic updates should work great for you. As always, though, we recommend ba
* Feature - PayFlow - Adds product-level option for Authorization or Sale. ([PFW-273](https://github.com/angelleye/paypal-woocommerce/pull/1223))([PFW-290](https://github.com/angelleye/paypal-woocommerce/pull/1231))
* Feature - PayFlow - Adds additional data for Address Verification to Woo order notes. ([PFW-276](https://github.com/angelleye/paypal-woocommerce/pull/1221))
* Tweak - REST CC - Adjustments to error display on failed payments. ([PFW-284](https://github.com/angelleye/paypal-woocommerce/pull/1225))
+* Tweak - PayFlow - Formatting adjustment for auth/capture AVS notes. ([PFW-293](https://github.com/angelleye/paypal-woocommerce/pull/1230))
* Tweak - CSS tweaks to resolve mobile checkout form field issues. ([PWF-268](https://github.com/angelleye/paypal-woocommerce/pull/1227))
* Tweak - Adjusts tool-tip related to Authorization and Capture functionality. ([PFW-291](https://github.com/angelleye/paypal-woocommerce/pull/1232))
* Fix - Express Checkout - Resolves a conflict with some themes where PayPal Smart Buttons would get cut off. ([PFW-266](https://github.com/angelleye/paypal-woocommerce/pull/1228))