Consistently trim and unslash search queries for the users list tables.

props aubreypwd.
fixes #26115.

Built from https://develop.svn.wordpress.org/trunk@27077


git-svn-id: http://core.svn.wordpress.org/trunk@26950 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrew Nacin 2014-02-02 22:10:12 +00:00
parent fb3985663a
commit 39e32ed1eb
2 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ class WP_MS_Users_List_Table extends WP_List_Table {
function prepare_items() {
global $usersearch, $role, $wpdb, $mode;
$usersearch = isset( $_REQUEST['s'] ) ? $_REQUEST['s'] : '';
$usersearch = isset( $_REQUEST['s'] ) ? wp_unslash( trim( $_REQUEST['s'] ) ) : '';
$users_per_page = $this->get_items_per_page( 'users_network_per_page' );

View File

@ -35,7 +35,7 @@ class WP_Users_List_Table extends WP_List_Table {
function prepare_items() {
global $role, $usersearch;
$usersearch = isset( $_REQUEST['s'] ) ? trim( $_REQUEST['s'] ) : '';
$usersearch = isset( $_REQUEST['s'] ) ? wp_unslash( trim( $_REQUEST['s'] ) ) : '';
$role = isset( $_REQUEST['role'] ) ? $_REQUEST['role'] : '';