Bug: When creating an account with invalid characters the error is "Username already taken" not "Invalid characters used"
Summary
When signing up for a new username, the validation gives a Username is already taken error message when user puts in symbols instead of the correct Please create a username with only alphanumeric characters message.
Steps to reproduce
- Go to
/users/sign_in - Starting filling out the
Registerform, in the username field, write a symbol such as@. - Sometimes, when you delete the symbol and reenter it, the proper error message will show.
Example Project
N/A
What is the current bug behavior?
The validation error shows Username is already taken instead of Please create a username with only alphanumeric characters
What is the expected correct behavior?
It should show the correct error message.
Relevant logs and/or screenshots
Output of checks
Results of GitLab environment info
Reproducible in GitLab.com
GitLab Enterprise Edition 10.7.0-rc7-ee 60b675d
Possible fixes
NOTE:
I believe _ and - are allowed in usernames - I don't know if that is typically considered alphanumeric, but we may need to change that error message as well if that is not the case.
Edited by Mark Fletcher