From fa4fed0f8077bd90327f27da2a66e40ce192c6ed Mon Sep 17 00:00:00 2001 From: Drew Jaynes Date: Tue, 6 Oct 2015 23:00:25 +0000 Subject: [PATCH] Login: Pass the `$errors` object as a parameter to the `lostpassword_post` hook. Props iamfriendly. Fixes #32116. Built from https://develop.svn.wordpress.org/trunk@34885 git-svn-id: http://core.svn.wordpress.org/trunk@34850 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/version.php | 2 +- wp-login.php | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/wp-includes/version.php b/wp-includes/version.php index b8a9b2006c..7e106701d6 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.4-alpha-34884'; +$wp_version = '4.4-alpha-34885'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. diff --git a/wp-login.php b/wp-login.php index 5b3daaae79..8f676d7d8a 100644 --- a/wp-login.php +++ b/wp-login.php @@ -295,8 +295,12 @@ function retrieve_password() { * Fires before errors are returned from a password reset request. * * @since 2.1.0 + * @since 4.4.0 Added the `$errors` parameter. + * + * @param WP_Error $errors A WP_Error object containing any errors generated + * by using invalid credentials. */ - do_action( 'lostpassword_post' ); + do_action( 'lostpassword_post', $errors ); if ( $errors->get_error_code() ) return $errors;