WordPress.org

Make WordPress Core

Ticket #5114: 5114.3.diff

File 5114.3.diff, 594 bytes (added by markjaquith, 7 years ago)
  • wp-includes/pluggable.php

     
    437437 
    438438        $allowed_hosts = (array) apply_filters('allowed_redirect_hosts', array($wpp['host']), $lp['host']); 
    439439 
    440         if ( isset($lp['host']) && !in_array($lp['host'], $allowed_hosts) ) 
     440        if ( isset($lp['host']) && ( !in_array($lp['host'], $allowed_hosts) && $lp['host'] != strtolower($wpp['host'])) ) 
    441441                $location = get_option('siteurl') . '/wp-admin/'; 
    442442 
    443443        wp_redirect($location, $status);