Revert "Flush term cache when saving product and settings closes #25375"
This reverts commit 8b0915c4e0
.
This commit is contained in:
parent
f6d77c206d
commit
503a218e85
|
@ -64,10 +64,6 @@ class WC_Settings_Products extends WC_Settings_Page {
|
|||
$settings = $this->get_settings( $current_section );
|
||||
WC_Admin_Settings::save_fields( $settings );
|
||||
|
||||
// Any time we update the product settings, we should flush the term count cache.
|
||||
$tools_controller = new WC_REST_System_Status_Tools_Controller();
|
||||
$tools_controller->execute_tool( 'recount_terms' );
|
||||
|
||||
if ( $current_section ) {
|
||||
do_action( 'woocommerce_update_options_' . $this->id . '_' . $current_section );
|
||||
}
|
||||
|
|
|
@ -272,9 +272,6 @@ class WC_Product_Data_Store_CPT extends WC_Data_Store_WP implements WC_Object_Da
|
|||
|
||||
$product->apply_changes();
|
||||
|
||||
// Any time we update the product, we should flush the term count cache.
|
||||
$tools_controller = new WC_REST_System_Status_Tools_Controller();
|
||||
$tools_controller->execute_tool( 'recount_terms' );
|
||||
do_action( 'woocommerce_update_product', $product->get_id(), $product );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue