mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-05 08:59:14 +08:00
Merge pull request #933 from woocommerce/PCP-954-compatibility-with-wc-high-performance-order-storage
Compatibility with WC High-Performance Order Storage
This commit is contained in:
commit
933cede8d6
7 changed files with 32 additions and 8 deletions
|
@ -277,7 +277,8 @@ class CardButtonGateway extends \WC_Payment_Gateway {
|
|||
if ( $this->subscription_helper->has_subscription( $order_id ) && $this->subscription_helper->is_subscription_change_payment() ) {
|
||||
$saved_paypal_payment = filter_input( INPUT_POST, 'saved_paypal_payment', FILTER_SANITIZE_STRING );
|
||||
if ( $saved_paypal_payment ) {
|
||||
update_post_meta( $order_id, 'payment_token_id', $saved_paypal_payment );
|
||||
$wc_order->update_meta_data( 'payment_token_id', $saved_paypal_payment );
|
||||
$wc_order->save();
|
||||
|
||||
return $this->handle_payment_success( $wc_order );
|
||||
}
|
||||
|
|
|
@ -425,7 +425,8 @@ class PayPalGateway extends \WC_Payment_Gateway {
|
|||
if ( $this->subscription_helper->has_subscription( $order_id ) && $this->subscription_helper->is_subscription_change_payment() ) {
|
||||
$saved_paypal_payment = filter_input( INPUT_POST, 'saved_paypal_payment', FILTER_SANITIZE_STRING );
|
||||
if ( $saved_paypal_payment ) {
|
||||
update_post_meta( $order_id, 'payment_token_id', $saved_paypal_payment );
|
||||
$wc_order->update_meta_data( 'payment_token_id', $saved_paypal_payment );
|
||||
$wc_order->save();
|
||||
|
||||
return $this->handle_payment_success( $wc_order );
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue