Restore previous filter order in WP_Query. See #14997
git-svn-id: http://svn.automattic.com/wordpress/trunk@15791 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b23b3a40af
commit
47f98231a5
|
@ -2186,13 +2186,13 @@ class WP_Query extends WP_Object_Query {
|
|||
// Apply post-paging filters on where and join. Only plugins that
|
||||
// manipulate paging queries should use these hooks.
|
||||
if ( !$q['suppress_filters'] ) {
|
||||
$distinct = apply_filters_ref_array( 'posts_distinct', array( $distinct, &$this ) );
|
||||
$fields = apply_filters_ref_array( 'posts_fields', array( $fields, &$this ) );
|
||||
$where = apply_filters_ref_array( 'posts_where_paged', array( $where, &$this ) );
|
||||
$join = apply_filters_ref_array( 'posts_join_paged', array( $join, &$this ) );
|
||||
$groupby = apply_filters_ref_array( 'posts_groupby', array( $groupby, &$this ) );
|
||||
$join = apply_filters_ref_array( 'posts_join_paged', array( $join, &$this ) );
|
||||
$orderby = apply_filters_ref_array( 'posts_orderby', array( $orderby, &$this ) );
|
||||
$distinct = apply_filters_ref_array( 'posts_distinct', array( $distinct, &$this ) );
|
||||
$limits = apply_filters_ref_array( 'post_limits', array( $limits, &$this ) );
|
||||
$fields = apply_filters_ref_array( 'posts_fields', array( $fields, &$this ) );
|
||||
|
||||
// Also apply a filter on all clauses at once, for convenience
|
||||
$clauses = array();
|
||||
|
@ -2212,12 +2212,12 @@ class WP_Query extends WP_Object_Query {
|
|||
|
||||
// Filter again for the benefit of caching plugins. Regular plugins should use the hooks above.
|
||||
if ( !$q['suppress_filters'] ) {
|
||||
$distinct = apply_filters_ref_array( 'posts_distinct_request',array( $distinct, &$this ) );
|
||||
$fields = apply_filters_ref_array( 'posts_fields_request', array( $fields, &$this ) );
|
||||
$where = apply_filters_ref_array( 'posts_where_request', array( $where, &$this ) );
|
||||
$join = apply_filters_ref_array( 'posts_join_request', array( $join, &$this ) );
|
||||
$groupby = apply_filters_ref_array( 'posts_groupby_request', array( $groupby, &$this ) );
|
||||
$join = apply_filters_ref_array( 'posts_join_request', array( $join, &$this ) );
|
||||
$orderby = apply_filters_ref_array( 'posts_orderby_request', array( $orderby, &$this ) );
|
||||
$distinct = apply_filters_ref_array( 'posts_distinct_request', array( $distinct, &$this ) );
|
||||
$fields = apply_filters_ref_array( 'posts_fields_request', array( $fields, &$this ) );
|
||||
$limits = apply_filters_ref_array( 'post_limits_request', array( $limits, &$this ) );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue