User: Invalidate `user_activation_key` on password update.
Props: sstoqnov, sergeybiryukov. Built from https://develop.svn.wordpress.org/trunk@47634 git-svn-id: http://core.svn.wordpress.org/trunk@47409 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
55cd633c37
commit
f7b4147bea
|
@ -1812,7 +1812,7 @@ function wp_insert_user( $userdata ) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( $update ) {
|
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'] = '';
|
$data['user_activation_key'] = '';
|
||||||
}
|
}
|
||||||
$wpdb->update( $wpdb->users, $data, compact( 'ID' ) );
|
$wpdb->update( $wpdb->users, $data, compact( 'ID' ) );
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.5-alpha-47633';
|
$wp_version = '5.5-alpha-47634';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue