Commit 6f0d90ec authored by Steve Gerbino's avatar Steve Gerbino

Fixed glitch that prevented the username to properly be created when

an existing combination of first name and last name had already
existed in the database.
parent d599a895
......@@ -65,6 +65,7 @@ function realname_registration_user($op, &$edit, &$account, $category = NULL) {
// Check if the username already exists in the database.
$original_username = $username;
while (db_result(db_query("SELECT COUNT(*) FROM {users} WHERE name = '%s';", $username))) {
$username = $original_username . ++$i;
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