mirror of
https://github.com/WordPress/WordPress.git
synced 2024-09-27 06:42:56 +02:00
Force GROUP BY when there's a tax query. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@16482 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
1baed284ed
commit
7879bcaee5
@ -1984,7 +1984,7 @@ class WP_Query {
|
||||
}
|
||||
}
|
||||
|
||||
if ( !empty($q['meta_key']) ) {
|
||||
if ( !empty( $this->tax_query ) || !empty( $q['meta_key'] ) ) {
|
||||
$groupby = "{$wpdb->posts}.ID";
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user