woocommerce_order_removed_coupon
Action hook fired when a coupon is removed from an order.
Usage
add_action( 'woocommerce_order_removed_coupon', 'wp_kama_woocommerce_order_removed_coupon_action', 10, 2 );
/**
* Function for `woocommerce_order_removed_coupon` action-hook.
*
* @param WC_Coupon $coupon_object The removed coupon object.
* @param WC_Order $order The current order object.
*
* @return void
*/
function wp_kama_woocommerce_order_removed_coupon_action( $coupon_object, $order ){
// action...
}
Changelog
| Since 10.8.0 | Introduced. |
Where the hook is called
woocommerce_order_removed_coupon
woocommerce/includes/abstracts/abstract-wc-order.php 1886
do_action( 'woocommerce_order_removed_coupon', $coupon_object, $this );