Taxonomy: Ensure that mods to query vars in pre_term_query callbacks have an effect.

Previously, it was possible to modify the `query_vars` array, but
the changes would be ignored after `pre_term_query` had finished
running.

Props jfarthing84.
Fixes #39354.
Built from https://develop.svn.wordpress.org/trunk@39625


git-svn-id: http://core.svn.wordpress.org/trunk@39565 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Boone Gorges 2016-12-21 03:02:40 +00:00
parent 4177e37593
commit 3ef41856bb
2 changed files with 2 additions and 2 deletions

View File

@ -305,7 +305,7 @@ class WP_Term_Query {
global $wpdb;
$this->parse_query( $this->query_vars );
$args = $this->query_vars;
$args = &$this->query_vars;
// Set up meta_query so it's available to 'pre_get_terms'.
$this->meta_query = new WP_Meta_Query();

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.8-alpha-39624';
$wp_version = '4.8-alpha-39625';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.