Automattic\WooCommerce\Internal\Caches
OrdersVersionStringInvalidator::handle_woocommerce_order_refunded
Handle the woocommerce_order_refunded hook.
Method of the class: OrdersVersionStringInvalidator{}
No Hooks.
Returns
null. Nothing (null).
Usage
$OrdersVersionStringInvalidator = new OrdersVersionStringInvalidator(); $OrdersVersionStringInvalidator->handle_woocommerce_order_refunded( $order_id, $refund_id ): void;
- $order_id(int) (required)
- The parent order ID.
- $refund_id(int) (required)
- The refund ID.
Changelog
| Since 10.6.0 | Introduced. |
OrdersVersionStringInvalidator::handle_woocommerce_order_refunded() OrdersVersionStringInvalidator::handle woocommerce order refunded code WC 10.7.0
public function handle_woocommerce_order_refunded( $order_id, $refund_id ): void {
$order_id = (int) $order_id;
$refund_id = (int) $refund_id;
$this->invalidate( $order_id );
$this->invalidate_refund( $refund_id );
$this->invalidate_order_refunds_list( $order_id );
$this->invalidate_refunds_list();
}