WordPress at a glance
filter is not described

query_vars filter-hook . WP 1.5.0

Filters the query variables whitelist before processing.

Allows (publicly allowed) query vars to be added, removed, or changed prior to executing the query. Needed to allow custom rewrite rules using your own arguments to work, or any other custom query variables you want to be publicly available.

Usage

add_filter( 'query_vars', 'filter_function_name_7339' );
function filter_function_name_7339( $public_query_vars ){
	// filter...

	return $public_query_vars;
}
$public_query_vars(string[])
The array of whitelisted query variable names.

Changelog

Since 1.5.0 Introduced.

Where the hook is called

WP::parse_request()
query_vars
WC_REST_Posts_Controller::get_allowed_query_vars()
query_vars
wp-includes/class-wp.php 287
$this->public_query_vars = apply_filters( 'query_vars', $this->public_query_vars );
woocommerce/packages/woocommerce-rest-api/src/Controllers/Version3/class-wc-rest-posts-controller.php 555
$valid_vars = apply_filters( 'query_vars', $wp->public_query_vars );

Where the hook is used (in WP core)

Usage not found!