WordPress.org

Make WordPress Core

Changeset 13847


Ignore:
Timestamp:
03/28/10 00:23:40 (4 years ago)
Author:
dd32
Message:

Correct Array style for returning Multiple HTTP Headers. See #12045

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/class-http.php

    r13725 r13847  
    451451                $key = strtolower( $key ); 
    452452                if ( isset( $newheaders[$key] ) ) { 
    453                     $newheaders[$key] = array( $newheaders[$key], trim( $value ) ); 
     453                    if ( !is_array($newheaders[$key]) ) 
     454                        $newheaders[$key] = array($newheaders[$key]); 
     455                    $newheaders[$key][] = trim( $value ); 
    454456                } else { 
    455457                    $newheaders[$key] = trim( $value ); 
Note: See TracChangeset for help on using the changeset viewer.