Remove stock level set tracking as this is done in JS now
This commit is contained in:
parent
4136a42e1e
commit
e998cc963c
|
@ -20,8 +20,6 @@ class WC_Products_Tracking {
|
|||
add_action( 'edit_post', array( $this, 'track_product_updated' ), 10, 2 );
|
||||
add_action( 'transition_post_status', array( $this, 'track_product_published' ), 10, 3 );
|
||||
add_action( 'created_product_cat', array( $this, 'track_product_category_created' ) );
|
||||
add_action( 'woocommerce_variation_set_stock', array( $this, 'track_product_stock_level_set' ), 10, 1 );
|
||||
add_action( 'woocommerce_product_set_stock', array( $this, 'track_product_stock_level_set' ), 10, 1 );
|
||||
add_action( 'add_meta_boxes_product', array( $this, 'track_product_updated_client_side' ), 10, 1 );
|
||||
}
|
||||
|
||||
|
@ -79,19 +77,6 @@ class WC_Products_Tracking {
|
|||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Send a Tracks event when a product's stock level is adjusted.
|
||||
*
|
||||
* @param WC_Product $product Product.
|
||||
*/
|
||||
public function track_product_stock_level_set( $product ) {
|
||||
$properties = array(
|
||||
'product_id' => $product->get_id(),
|
||||
);
|
||||
|
||||
WC_Tracks::record_event( 'product_stock_level_set', $properties );
|
||||
}
|
||||
|
||||
/**
|
||||
* Send a Tracks event when a product is published.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue