Pass references and more context to the new 'user_profile_update_errors' hook. Fixes #9302.
git-svn-id: https://develop.svn.wordpress.org/trunk@11441 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
9e3a2b0210
commit
bd9784b05e
@ -178,8 +178,9 @@ function edit_user( $user_id = 0 ) {
|
||||
$errors->add( 'email_exists', __('<strong>ERROR</strong>: This email is already registered, please choose another one.'), array( 'form-field' => 'email' ) );
|
||||
}
|
||||
|
||||
do_action('user_profile_update_errors', $errors);
|
||||
|
||||
// Allow plugins to return there own errors.
|
||||
do_action_ref_array('user_profile_update_errors', array ( &$errors, $update, &$user ) );
|
||||
|
||||
if ( $errors->get_error_codes() )
|
||||
return $errors;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user