User Query: Don't blindly re-append new meta queries for capabilities.
fixes #21119. Built from https://develop.svn.wordpress.org/trunk@28087 git-svn-id: http://core.svn.wordpress.org/trunk@27918 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
d50e4bc08c
commit
91971b28a7
|
@ -665,8 +665,10 @@ class WP_User_Query {
|
|||
$cap_meta_query['compare'] = 'like';
|
||||
}
|
||||
|
||||
if ( empty( $qv['meta_query'] ) || ! in_array( $cap_meta_query, $qv['meta_query'], true ) ) {
|
||||
$qv['meta_query'][] = $cap_meta_query;
|
||||
}
|
||||
}
|
||||
|
||||
$meta_query = new WP_Meta_Query();
|
||||
$meta_query->parse_query_vars( $qv );
|
||||
|
|
Loading…
Reference in New Issue