uid != $currentUser->uid) { return FALSE; } return TRUE; } function _mkbh_account_page_user_mail_available($mail, $currentUser) { $existingUser = user_load_by_mail($mail); if (!empty($existingUser) && $existingUser->uid != $currentUser->uid) { return FALSE; } return TRUE; }