Fix failing tests for canonical extensions due to 49583 (#50519)

Revert the addition of a new parameter in the woocommerce_product_set_stock hook, which was causing unit tests to fail in some extensions.
This commit is contained in:
Naman Malhotra 2024-08-10 03:38:23 +05:30 committed by Jorge Torres
parent 34890a4784
commit d36550c40d
1 changed files with 2 additions and 2 deletions

View File

@ -300,8 +300,8 @@ function wc_trigger_stock_change_actions( $product ) {
do_action( 'woocommerce_low_stock', $product ); do_action( 'woocommerce_low_stock', $product );
} }
} }
add_action( 'woocommerce_variation_set_stock', 'wc_trigger_stock_change_actions', 10, 1 ); add_action( 'woocommerce_variation_set_stock', 'wc_trigger_stock_change_actions' );
add_action( 'woocommerce_product_set_stock', 'wc_trigger_stock_change_actions', 10, 1 ); add_action( 'woocommerce_product_set_stock', 'wc_trigger_stock_change_actions' );
/** /**
* Increase stock levels for items within an order. * Increase stock levels for items within an order.