Commit 8cc75202 authored by alexpott's avatar alexpott

Issue #1996644 by abghosh82 | joachim: Fixed user_login_name_validate() uses...

Issue #1996644 by abghosh82 | joachim: Fixed user_login_name_validate() uses isset() where other user login form validation handlers use !empty().
parent 7846ad6f
......@@ -1273,7 +1273,7 @@ function user_login_default_validators() {
* A FAPI validate handler. Sets an error if supplied username has been blocked.
*/
function user_login_name_validate($form, &$form_state) {
if (isset($form_state['values']['name']) && user_is_blocked($form_state['values']['name'])) {
if (!empty($form_state['values']['name']) && user_is_blocked($form_state['values']['name'])) {
// Blocked in user administration.
form_set_error('name', t('The username %name has not been activated or is blocked.', array('%name' => $form_state['values']['name'])));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment