WordPress.org

Make WordPress Core

Changeset 20024


Ignore:
Timestamp:
02/28/2012 08:37:47 PM (9 years ago)
Author:
ryan
Message:

Return to apply_filters_ref_array() for back compat with callbacks that specify a ref for the args. Props scribu. see #18536

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/query.php

    r19932 r20024  
    26102610
    26112611        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 ) );
    26132613        }
    26142614
     
    27782778            return;
    27792779
    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 ) );
    27822782
    27832783        $this->max_num_pages = ceil( $this->found_posts / $q['posts_per_page'] );
Note: See TracChangeset for help on using the changeset viewer.