WordPress.org

Make WordPress Core

Ticket #6675: reloc_wp_auth.diff

File reloc_wp_auth.diff, 813 bytes (added by ryan, 10 years ago)

Move wp_authenticate action up

  • wp-includes/user.php

     
    1919        else
    2020                $credentials['remember'] = false;
    2121
     22        do_action_ref_array('wp_authenticate', array(&$credentials['user_login'], &$credentials['user_password']));
     23
    2224        // If no credential info provided, check cookie.
    2325        if ( empty($credentials['user_login']) && empty($credentials['user_password']) ) {
    2426                        $user = wp_validate_auth_cookie();
     
    4244                return $error;
    4345        }
    4446
    45         do_action_ref_array('wp_authenticate', array(&$credentials['user_login'], &$credentials['user_password']));
    46 
    4747        $user = wp_authenticate($credentials['user_login'], $credentials['user_password']);
    4848        if ( is_wp_error($user) )
    4949                return $user;