Make WordPress Core


Ignore:
Timestamp:
07/07/2015 07:28:46 PM (8 years ago)
Author:
wonderboymusic
Message:

In wp_insert_user(), comparing an email address against the user's old email address should not be case-sensitive.

Adds unit tests.

Props tyxla.
Fixes #32158.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/user.php

    r33023 r33115  
    19461946     * accordingly.
    19471947     */
    1948     if ( ( ! $update || ( ! empty( $old_user_data ) && $user_email !== $old_user_data->user_email ) )
     1948    if ( ( ! $update || ( ! empty( $old_user_data ) && 0 !== strcasecmp( $user_email, $old_user_data->user_email ) ) )
    19491949        && ! defined( 'WP_IMPORTING' )
    19501950        && email_exists( $user_email )
Note: See TracChangeset for help on using the changeset viewer.