Automattic\WooCommerce\Internal\Caches

OrdersVersionStringInvalidator::handle_woocommerce_update_orderpublicWC 10.6.0

Handle the woocommerce_update_order hook.

Метод класса: OrdersVersionStringInvalidator{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$OrdersVersionStringInvalidator = new OrdersVersionStringInvalidator();
$OrdersVersionStringInvalidator->handle_woocommerce_update_order( $order_id, $order ): void;
$order_id(int) (обязательный)
The order ID.
$order(WC_Order) (обязательный)
The order object.

Список изменений

С версии 10.6.0 Введена.

Код OrdersVersionStringInvalidator::handle_woocommerce_update_order() WC 11.0.1

public function handle_woocommerce_update_order( $order_id, $order ): void {
	$order_id = (int) $order_id;
	$this->invalidate( $order_id );

	if ( $this->did_customer_change( $order_id, $order ) ) {
		$this->invalidate_orders_list();
	}

	unset( $this->pre_save_customer_ids[ $order_id ] );
}