mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
current user cleanup
git-svn-id: https://develop.svn.wordpress.org/trunk@3566 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -101,7 +101,7 @@ function wp_insert_user($userdata) {
|
||||
}
|
||||
|
||||
function wp_update_user($userdata) {
|
||||
global $wpdb, $current_user;
|
||||
global $wpdb;
|
||||
|
||||
$ID = (int) $userdata['ID'];
|
||||
|
||||
@@ -122,6 +122,7 @@ function wp_update_user($userdata) {
|
||||
$user_id = wp_insert_user($userdata);
|
||||
|
||||
// Update the cookies if the password changed.
|
||||
$current_user = wp_get_current_user();
|
||||
if( $current_user->id == $ID ) {
|
||||
if ( isset($plaintext_pass) ) {
|
||||
wp_clearcookie();
|
||||
|
||||
Reference in New Issue
Block a user