[wp-trac] [WordPress Trac] #32158: wp_update_user() fails if email field case doesn't match

WordPress Trac noreply at wordpress.org
Tue Apr 28 03:15:59 UTC 2015


#32158: wp_update_user() fails if email field case doesn't match
----------------------------+-----------------------------
 Reporter:  davidjbullock   |      Owner:
     Type:  defect (bug)    |     Status:  new
 Priority:  normal          |  Milestone:  Awaiting Review
Component:  Users           |    Version:  4.2
 Severity:  normal          |   Keywords:
  Focuses:  administration  |
----------------------------+-----------------------------
 When calling wp_update_user() if the case of the current email address
 matches the old email address, with the exception of the case being
 different, than then entire wp_update_user() call fails with an error that
 the email address is already in use.

 example:
 test @ example.com vs. test @ Example.com

 This can be easily tested in the user editor by opening a usser, changing
 the email case only, and trying to save it.

 The behavior is inconsistent in handling email addresses as either case-
 sensitive or not.  In theory the LHS of the email address could be case
 sensitive, but this not the case in practice.

 In any case, the change should succeed, if the check is case sensitive,
 then the email addresses are different and there is no duplication.  If
 the addresses are the same, then it should succeed because its updating
 the current record.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/32158>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list