Opened 6 years ago
Last modified 2 months ago
#50694 assigned defect (bug)
Impossible to add user to network site when username / email are both emails and different values
| Reported by: | elrae | Owned by: | realloc |
|---|---|---|---|
| Priority: | normal | Milestone: | Awaiting Review |
| Component: | Networks and Sites | Version: | |
| Severity: | normal | Keywords: | reporter-feedback close |
| Cc: | Focuses: | administration, multisite |
Description
If you have a network site and create a user where the username is an email address (myemail@…) and your email address is different (otheremail@…) you cannot add a user to the network site. Under the Add Existing User section it will find the user you're trying to add and autofill it, but when you try to actually add it, it tells you it's not a valid user.
Steps to reproduce:
- Create a network site
- Add a new user where their username is one email address and the email address is a different one
- Add a new network site under your main one
- Try to add your user to that newly created main one
I ran into this issue because I created some users initially using their email address as a username, and then their email address changed. We can't change username so the only thing I could do was update their email on their account which I did. Then this bug popped up.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
I was unable to reproduce this. When trying to create a user with an email address as the username, WordPress returns the error:
Usernames can only contain lowercase letters (a-z) and numbers.
This suggests the validation already prevents the scenario described in this ticket. If it was ever possible to use an email as a username, it appears to have been addressed since. I'd recommend closing this as a non-issue.