WordPress.org

Make WordPress Core

Ticket #13130: 13130-3.diff

File 13130-3.diff, 694 bytes (added by blepoxp, 8 years ago)

Adds WP_IMPORTING to conditional

  • wp-includes/registration.php

     
    140140                $user_email = '';
    141141        $user_email = apply_filters('pre_user_email', $user_email);
    142142
    143         if ( !$update && email_exists($user_email) )
    144                 return new WP_Error('existing_user_email', __('This email address is already registered.') );
     143        if ( !$update && !defined( 'WP_IMPORTING' ) && email_exists( $user_email ) )
     144                return new WP_Error( 'existing_user_email', __( 'This email address is already registered.' ) );
    145145
    146146        if ( empty($display_name) )
    147147                $display_name = $user_login;