Opened 10 years ago
Last modified 7 years ago
#36303 new defect (bug)
edit_user() will give PHP Notices if user_login is unset on add.
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 4.4.2 |
| Component: | Users | Keywords: | |
| Focuses: | Cc: |
Description
If you call edit_user() programmatically to add a user then if $_POST['user_login'] isn't set you'll get multiple PHP Notices of Undefined property: stdClass::$user_login (as well as a WP error message). The attached patch sets it to blank on add if unset (the WP error message will still occur).
Attachments (1)
Note: See
TracTickets for help on using
tickets.
Set $user->user_login to blank if adding and no $_POSTuser_login? set.