Login: Pass the $errors
object as a parameter to the lostpassword_post
hook.
Props iamfriendly. Fixes #32116. git-svn-id: https://develop.svn.wordpress.org/trunk@34885 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
0d1c1381b3
commit
f2188269ce
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user