Opened 9 years ago
Closed 9 years ago
#33804 closed enhancement (fixed)
Improve error handling when creating a new site and the user couldn't be created
Reported by: | ocean90 | Owned by: | jeremyfelt |
---|---|---|---|
Milestone: | 4.4 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Networks and Sites | Keywords: | has-patch commit |
Focuses: | multisite | Cc: |
Description
There was an error creating the user.
Source: trunk/src/wp-admin/network/site-new.php#L95
You'll see this message when creating a new site, the email doesn't exist but the domain exists as a username because it's used as a fallback.
I think we should add a username_exists()
check before calling wpmu_create_user()
here.
Attachments (6)
Change History (12)
#2
@
9 years ago
- Milestone changed from Awaiting Review to 4.4
33804.2.diff uses the text "The domain or path entered conflicts with an existing username."
I'd be okay changing the error message now for clarity. It would be nice to decouple this experience in the future. If we're creating a site and assigning an admin user, we shouldn't have to care about creating a user at the same time.
#3
@
9 years ago
@jeremyfelt
Updated error message has more clarity than previous one.
Thanks for suggestion.
Added check for username exist