Automattic\WooCommerce\Internal\Caches

OrdersVersionStringInvalidator::handle_woocommerce_untrash_orderpublicWC 10.6.0

Handle the woocommerce_untrash_order hook.

Method of the class: OrdersVersionStringInvalidator{}

No Hooks.

Returns

null. Nothing (null).

Usage

$OrdersVersionStringInvalidator = new OrdersVersionStringInvalidator();
$OrdersVersionStringInvalidator->handle_woocommerce_untrash_order( $order_id, $previous_status ): void;
$order_id(int) (required)
The order ID.
$previous_status(string) (required)
The previous order status before trashing.

Changelog

Since 10.6.0 Introduced.

OrdersVersionStringInvalidator::handle_woocommerce_untrash_order() code WC 10.8.1

public function handle_woocommerce_untrash_order( $order_id, $previous_status ): void {
	$this->invalidate( (int) $order_id );
	$this->invalidate_orders_list();
}