Remove a one-time variable from `edit_user()` added in [35189].

See #27317.

git-svn-id: https://develop.svn.wordpress.org/trunk@35190 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2015-10-15 05:45:50 +00:00
parent e675e2ccf0
commit 3d7aa47df8
1 changed files with 1 additions and 2 deletions

View File

@ -143,8 +143,7 @@ function edit_user( $user_id = 0 ) {
$errors->add( 'user_login', __( '<strong>ERROR</strong>: This username is already registered. Please choose another one.' ));
/** This filter is documented in wp-includes/user-functions.php */
$usernames = apply_filters( 'illegal_user_logins', array() );
if ( in_array( $user->user_login, $usernames ) ) {
if ( in_array( $user->user_login, apply_filters( 'illegal_user_logins', array() ) ) ) {
$errors->add( 'illegal_user_login', __( '<strong>ERROR</strong>: Sorry, that username is not allowed.' ) );
}