Automattic\WooCommerce\Utilities
OrderUtil::unknown_orders_data_store_in_use
Checks if the data store currently in use for orders is unknown (none of the ones managed by WooCommerce core).
Метод класса: OrderUtil{}
Хуков нет.
Возвращает
bool. True if the data store currently in use for orders is neither the HPOS one nor the CPT one.
Использование
$result = OrderUtil::unknown_orders_data_store_in_use(): bool;
Код OrderUtil::unknown_orders_data_store_in_use() OrderUtil::unknown orders data store in use WC 11.3.0
public static function unknown_orders_data_store_in_use(): bool {
return ! self::custom_orders_table_usage_is_enabled() &&
( \WC_Order_Data_Store_CPT::class !== \WC_Data_Store::load( 'order' )->get_current_class_name() );
}