Invalidate password keys when a user's email changes.
Built from https://develop.svn.wordpress.org/trunk@30430 git-svn-id: http://core.svn.wordpress.org/trunk@30425 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
e7614d6c45
commit
fce07e17eb
|
@ -1885,6 +1885,9 @@ function wp_insert_user( $userdata ) {
|
||||||
$data = wp_unslash( $compacted );
|
$data = wp_unslash( $compacted );
|
||||||
|
|
||||||
if ( $update ) {
|
if ( $update ) {
|
||||||
|
if ( $user_email !== $old_user_data->user_email ) {
|
||||||
|
$data['user_activation_key'] = '';
|
||||||
|
}
|
||||||
$wpdb->update( $wpdb->users, $data, compact( 'ID' ) );
|
$wpdb->update( $wpdb->users, $data, compact( 'ID' ) );
|
||||||
$user_id = (int) $ID;
|
$user_id = (int) $ID;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '4.1-beta1-30425';
|
$wp_version = '4.1-beta1-30430';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 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