Don't match partial roles in `WP_User_Query`.
Because 'role=ocean90' shouldn't match 'role=bocean901'. Props bocean901, ocean90. Fixes #22212. Built from https://develop.svn.wordpress.org/trunk@35101 git-svn-id: http://core.svn.wordpress.org/trunk@35066 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
e7c2544a89
commit
ff0b621719
|
@ -304,7 +304,7 @@ class WP_User_Query {
|
|||
foreach ( $roles as $role ) {
|
||||
$roles_clauses[] = array(
|
||||
'key' => $wpdb->get_blog_prefix( $blog_id ) . 'capabilities',
|
||||
'value' => $role,
|
||||
'value' => '"' . $role . '"',
|
||||
'compare' => 'LIKE',
|
||||
);
|
||||
}
|
||||
|
@ -317,7 +317,7 @@ class WP_User_Query {
|
|||
foreach ( $role__in as $role ) {
|
||||
$role__in_clauses[] = array(
|
||||
'key' => $wpdb->get_blog_prefix( $blog_id ) . 'capabilities',
|
||||
'value' => $role,
|
||||
'value' => '"' . $role . '"',
|
||||
'compare' => 'LIKE',
|
||||
);
|
||||
}
|
||||
|
@ -330,7 +330,7 @@ class WP_User_Query {
|
|||
foreach ( $role__not_in as $role ) {
|
||||
$role__not_in_clauses[] = array(
|
||||
'key' => $wpdb->get_blog_prefix( $blog_id ) . 'capabilities',
|
||||
'value' => $role,
|
||||
'value' => '"' . $role . '"',
|
||||
'compare' => 'NOT LIKE',
|
||||
);
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.4-alpha-35100';
|
||||
$wp_version = '4.4-alpha-35101';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue