Automattic\WooCommerce\Caches
OrderCountCache::get_saved_statuses_for_type
Retrieves the list of known statuses by order type. A cached array of statuses is saved per order type for improved backward compatibility with some of the extensions that don't register all statuses they use with WooCommerce.
Метод класса: OrderCountCache{}
Хуков нет.
Возвращает
Строку[].
Использование
// private - только в коде основоного (родительского) класса $result = $this->get_saved_statuses_for_type( $order_type );
- $order_type(строка) (обязательный)
- The type of order.
Код OrderCountCache::get_saved_statuses_for_type() OrderCountCache::get saved statuses for type WC 10.3.6
private function get_saved_statuses_for_type( string $order_type ) {
$statuses = wp_cache_get( $this->get_saved_statuses_cache_key( $order_type ) );
if ( ! is_array( $statuses ) ) {
$statuses = array();
}
return $statuses;
}