mirror of
https://github.com/WordPress/WordPress.git
synced 2025-01-24 17:21:34 +01:00
Login and Registration: Simplify the test for wp_signon()
added in [46640].
Make sure it actually tests the change in behavior, previously it passed both before and after the patch. Add `wp_unslash()` to the last remaining instance of `$_POST['user_login']` that didn't have it. See #38744. Built from https://develop.svn.wordpress.org/trunk@46650 git-svn-id: http://core.svn.wordpress.org/trunk@46450 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b5bf852dfe
commit
4ef6154be2
@ -13,7 +13,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.4-alpha-46649';
|
||||
$wp_version = '5.4-alpha-46650';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
@ -373,7 +373,7 @@ function retrieve_password() {
|
||||
$errors->add( 'invalid_email', __( '<strong>ERROR</strong>: There is no account with that username or email address.' ) );
|
||||
}
|
||||
} else {
|
||||
$login = trim( $_POST['user_login'] );
|
||||
$login = trim( wp_unslash( $_POST['user_login'] ) );
|
||||
$user_data = get_user_by( 'login', $login );
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user