From 84d03d3bf99a423d702403713193c5ae095b9ec1 Mon Sep 17 00:00:00 2001 From: Beka Rice Date: Fri, 19 Apr 2019 14:21:17 -0400 Subject: [PATCH] Tweak: update paying customer information on payment complete --- includes/wc-user-functions.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/wc-user-functions.php b/includes/wc-user-functions.php index 4932b66f998..051e5297197 100644 --- a/includes/wc-user-functions.php +++ b/includes/wc-user-functions.php @@ -237,7 +237,7 @@ function wc_update_new_customer_past_orders( $customer_id ) { } /** - * Order Status completed - This is a paying customer. + * Order payment completed - This is a paying customer. * * @param int $order_id Order ID. */ @@ -251,7 +251,7 @@ function wc_paying_customer( $order_id ) { $customer->save(); } } -add_action( 'woocommerce_order_status_completed', 'wc_paying_customer' ); +add_action( 'woocommerce_payment_complete', 'wc_paying_customer' ); /** * Checks if a user (by email or ID or both) has bought an item.