WordPress.org

Make WordPress Core

Changeset 28738


Ignore:
Timestamp:
06/11/2014 05:57:39 PM (6 years ago)
Author:
wonderboymusic
Message:

Don't use variable variables in WP_Comment_Query::query().

See #27881.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/comment.php

    r28720 r28738  
    444444         */
    445445        $clauses = apply_filters_ref_array( 'comments_clauses', array( compact( $pieces ), &$this ) );
    446         foreach ( $pieces as $piece )
    447             $$piece = isset( $clauses[ $piece ] ) ? $clauses[ $piece ] : '';
     446
     447        $fields = isset( $clauses[ 'fields' ] ) ? $clauses[ 'fields' ] : '';
     448        $join = isset( $clauses[ 'join' ] ) ? $clauses[ 'join' ] : '';
     449        $where = isset( $clauses[ 'where' ] ) ? $clauses[ 'where' ] : '';
     450        $orderby = isset( $clauses[ 'orderby' ] ) ? $clauses[ 'orderby' ] : '';
     451        $order = isset( $clauses[ 'order' ] ) ? $clauses[ 'order' ] : '';
     452        $limits = isset( $clauses[ 'limits' ] ) ? $clauses[ 'limits' ] : '';
     453        $groupby = isset( $clauses[ 'groupby' ] ) ? $clauses[ 'groupby' ] : '';
    448454
    449455        if ( $groupby ) {
Note: See TracChangeset for help on using the changeset viewer.