Changeset 19056
- Timestamp:
- 10/24/2011 09:31:30 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-login.php
r19028 r19056 169 169 $errors = new WP_Error(); 170 170 171 if ( empty( $_POST['user_login'] ) && empty( $_POST['user_email'] ) )171 if ( empty( $_POST['user_login'] ) ) { 172 172 $errors->add('empty_username', __('<strong>ERROR</strong>: Enter a username or e-mail address.')); 173 174 if ( strpos($_POST['user_login'], '@') ) { 175 $user_data = get_user_by('email', trim($_POST['user_login'])); 176 if ( empty($user_data) ) 173 } else if ( strpos( $_POST['user_login'], '@' ) ) { 174 $user_data = get_user_by( 'email', trim( $_POST['user_login'] ) ); 175 if ( empty( $user_data ) ) 177 176 $errors->add('invalid_email', __('<strong>ERROR</strong>: There is no user registered with that email address.')); 178 177 } else {
Note: See TracChangeset
for help on using the changeset viewer.