Ticket #21982: check_wp_authenticate_cookie.patch
File check_wp_authenticate_cookie.patch, 596 bytes (added by , 12 years ago) |
---|
-
wp-includes/user.php
117 117 * Authenticate the user using the WordPress auth cookie. 118 118 */ 119 119 function wp_authenticate_cookie($user, $username, $password) { 120 if ( is_a($user, 'WP_User') ) { return $user; } 121 122 if ( empty($username) && empty($password) ) { 120 if ( !is_a($user, 'WP_User') && empty($username) && empty($password) ) { 123 121 $user_id = wp_validate_auth_cookie(); 124 122 if ( $user_id ) 125 123 return new WP_User($user_id);