WordPress.org

Make WordPress Core

Ticket #7784: 7784.001.diff

File 7784.001.diff, 719 bytes (added by AaronCampbell, 6 years ago)
  • trunk/wp-includes/registration.php

     
    115115                $user_pass = wp_hash_password($user_pass); 
    116116        } 
    117117 
     118        // First, get all of the original fields 
     119        $oldUserData = get_userdata($ID); 
     120 
    118121        $user_login = sanitize_user($user_login, true); 
    119122        $user_login = apply_filters('pre_user_login', $user_login); 
    120123 
     
    199202        wp_cache_delete($user_login, 'userlogins'); 
    200203 
    201204        if ( $update ) 
    202                 do_action('profile_update', $user_id); 
     205                do_action('profile_update', $user_id, $oldUserData); 
    203206        else 
    204207                do_action('user_register', $user_id); 
    205208