Make WordPress Core

Changeset 44186


Ignore:
Timestamp:
12/14/2018 05:05:58 PM (6 years ago)
Author:
desrosj
Message:

Networks and Sites: Fix incorrect variable location.

This fixes an issue introduced in [44166] where the $groupby variable was inserted too low in the get_site_ids() function while merging [43832] into trunk. The merged location did not account for a new conditional statement that existed only in trunk, and would have resulted in values assigned to $groupby being erased in certain scenarios.

Props spacedmonkey.

See #44416.
Fixes #45582.

File:
1 edited

Legend:

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

    r44166 r44186  
    571571        }
    572572
    573         $join = '';
     573        $join    = '';
     574        $groupby = '';
    574575
    575576        if ( ! empty( $this->meta_query_clauses ) ) {
     
    585586
    586587        $where = implode( ' AND ', $this->sql_clauses['where'] );
    587 
    588         $groupby = '';
    589588
    590589        $pieces = array( 'fields', 'join', 'where', 'orderby', 'limits', 'groupby' );
Note: See TracChangeset for help on using the changeset viewer.