From c054a2803b39aa54797edd3391a12649de65c630 Mon Sep 17 00:00:00 2001 From: Dominic Vermeulen-Smith Date: Tue, 6 Oct 2020 17:38:07 +0100 Subject: [PATCH] issue #24631 - Updated needs payment check to use order --- includes/class-wc-checkout.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wc-checkout.php b/includes/class-wc-checkout.php index 195c8c2d7e5..9a90cbef4c0 100644 --- a/includes/class-wc-checkout.php +++ b/includes/class-wc-checkout.php @@ -1155,7 +1155,7 @@ class WC_Checkout { do_action( 'woocommerce_checkout_order_processed', $order_id, $posted_data, $order ); - if ( WC()->cart->needs_payment() ) { + if ( $order->needs_payment() ) { $this->process_order_payment( $order_id, $posted_data['payment_method'] ); } else { $this->process_order_without_payment( $order_id );