Some password reset filters

git-svn-id: https://develop.svn.wordpress.org/trunk@7016 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2008-02-25 07:41:13 +00:00
parent bc0893dfc2
commit b96041289b
1 changed files with 3 additions and 2 deletions

View File

@ -91,6 +91,7 @@ function retrieve_password() {
if ( empty($key) ) {
// Generate something random for a key...
$key = wp_generate_password();
do_action('retrieve_password_key', $user_login, $key);
// Now insert the new md5 key into the db
$wpdb->query("UPDATE $wpdb->users SET user_activation_key = '$key' WHERE user_login = '$user_login'");
}
@ -118,7 +119,7 @@ function reset_password($key) {
if ( empty( $user ) )
return new WP_Error('invalid_key', __('Invalid key'));
do_action('password_reset');
do_action('password_reset', $user);
// Generate something random for a password...
$new_pass = wp_generate_password();
@ -413,4 +414,4 @@ default:
break;
} // end action switch
?>
?>