User: Invalidate user_activation_key on password update.

Brings the changes in [47634] to the 5.4 branch.

Props: sstoqnov, sergeybiryukov.

Built from https://develop.svn.wordpress.org/branches/5.4@47640


git-svn-id: http://core.svn.wordpress.org/branches/5.4@47415 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
whyisjake 2020-04-29 15:49:07 +00:00
parent 0c86613369
commit 439012a2ca
2 changed files with 2 additions and 2 deletions

View File

@ -1803,7 +1803,7 @@ function wp_insert_user( $userdata ) {
}
if ( $update ) {
if ( $user_email !== $old_user_data->user_email ) {
if ( $user_email !== $old_user_data->user_email || $user_pass !== $old_user_data->user_pass ) {
$data['user_activation_key'] = '';
}
$wpdb->update( $wpdb->users, $data, compact( 'ID' ) );

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.4.1-RC1-47639';
$wp_version = '5.4.1-RC1-47640';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.