Make WordPress Core

Ticket #34028: 34028.3.diff

File 34028.3.diff, 755 bytes (added by mdawaffe, 9 years ago)

Correct logic

  • wp-includes/pluggable.php

     
    13671367         */
    13681368        $allowed_hosts = (array) apply_filters( 'allowed_redirect_hosts', array( $wpp['host'], $site['host'] ), isset( $lp['host'] ) ? $lp['host'] : '' );
    13691369
    1370         if ( isset($lp['host']) && ( ! in_array( $lp['host'], $allowed_hosts ) && ( $lp['host'] != strtolower( $wpp['host'] ) || $lp['host'] != strtolower( $site['host'] ) ) ) )
     1370        if ( isset($lp['host']) && ! in_array( $lp['host'], $allowed_hosts ) && $lp['host'] != strtolower( $wpp['host'] ) && $lp['host'] != strtolower( $site['host'] ) )
    13711371                $location = $default;
    13721372
    13731373        return $location;