Automattic\WooCommerce\Admin\API\Reports\Categories

DataStore::get_included_categories_array()protectedWC 1.0

Returns an array of ids of included categories, based on query arguments from the user.

Method of the class: DataStore{}

No Hooks.

Return

String.

Usage

// protected - for code of main (parent) or child class
$result = $this->get_included_categories_array( $query_args );
$query_args(array) (required)
Parameters supplied by the user.

DataStore::get_included_categories_array() code WC 8.6.1

protected function get_included_categories_array( $query_args ) {
	if ( isset( $query_args['category_includes'] ) && is_array( $query_args['category_includes'] ) && count( $query_args['category_includes'] ) > 0 ) {
		return $query_args['category_includes'];
	}
	return array();
}