mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-16 19:46:21 +00:00
Fix 'count' in WP_Comment_Query
when using 'meta_query'.
Props heshiming, desaiuditd. Fixes #23369. Built from https://develop.svn.wordpress.org/trunk@30026 git-svn-id: http://core.svn.wordpress.org/trunk@30026 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
a8f8a655f2
commit
3179629853
@ -559,8 +559,11 @@ class WP_Comment_Query {
|
||||
$clauses = $this->meta_query->get_sql( 'comment', $wpdb->comments, 'comment_ID', $this );
|
||||
$join .= $clauses['join'];
|
||||
$where .= $clauses['where'];
|
||||
|
||||
if ( ! $this->query_vars['count'] ) {
|
||||
$groupby = "{$wpdb->comments}.comment_ID";
|
||||
}
|
||||
}
|
||||
|
||||
$date_query = $this->query_vars['date_query'];
|
||||
if ( ! empty( $date_query ) && is_array( $date_query ) ) {
|
||||
|
@ -4,7 +4,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.1-alpha-30025';
|
||||
$wp_version = '4.1-alpha-30026';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
Loading…
x
Reference in New Issue
Block a user