added remove/restore cart item hooks
This commit is contained in:
parent
35b09bf282
commit
f8567680da
|
@ -948,6 +948,8 @@ class WC_Cart {
|
|||
|
||||
unset( $this->cart_contents[ $cart_item_key ] );
|
||||
|
||||
do_action( 'woocommerce_cart_item_removed', $cart_item_key, $this );
|
||||
|
||||
$this->calculate_totals();
|
||||
|
||||
return true;
|
||||
|
@ -969,6 +971,8 @@ class WC_Cart {
|
|||
|
||||
unset( $this->removed_cart_contents[ $cart_item_key ] );
|
||||
|
||||
do_action( 'woocommerce_cart_item_restored', $cart_item_key, $this );
|
||||
|
||||
$this->calculate_totals();
|
||||
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue