diff --git wp-includes/query.php wp-includes/query.php
index 4174246..c621470 100644
|
|
class WP_Query { |
2609 | 2609 | $this->request = $old_request = "SELECT $found_rows $distinct $fields FROM $wpdb->posts $join WHERE 1=1 $where $groupby $orderby $limits"; |
2610 | 2610 | |
2611 | 2611 | if ( !$q['suppress_filters'] ) { |
2612 | | $this->request = apply_filters( 'posts_request', $this->request, $this ); |
| 2612 | $this->request = apply_filters_ref_array( 'posts_request', array( $this->request, &$this ) ); |
2613 | 2613 | } |
2614 | 2614 | |
2615 | 2615 | if ( 'ids' == $q['fields'] ) { |
… |
… |
class WP_Query { |
2777 | 2777 | if ( $q['no_found_rows'] || empty( $limits ) ) |
2778 | 2778 | return; |
2779 | 2779 | |
2780 | | $this->found_posts = $wpdb->get_var( apply_filters( 'found_posts_query', 'SELECT FOUND_ROWS()', $this ) ); |
2781 | | $this->found_posts = apply_filters( 'found_posts', $this->found_posts, $this ); |
| 2780 | $this->found_posts = $wpdb->get_var( apply_filters_ref_array( 'found_posts_query', array( 'SELECT FOUND_ROWS()', &$this ) ) ); |
| 2781 | $this->found_posts = apply_filters_ref_array( 'found_posts', array( $this->found_posts, &$this ) ); |
2782 | 2782 | |
2783 | 2783 | $this->max_num_pages = ceil( $this->found_posts / $q['posts_per_page'] ); |
2784 | 2784 | } |