WordPress.org

Make WordPress Core

Changeset 22303


Ignore:
Timestamp:
10/25/2012 08:38:55 PM (6 years ago)
Author:
nacin
Message:

Avoid 'headers already sent' messages for header_remove() the same way we currently do with header(). props ryan. fixes #22258.

Location:
trunk/wp-includes
Files:
2 edited

Legend:

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

    r22283 r22303  
    383383
    384384        if ( isset( $headers['Last-Modified'] ) && empty( $headers['Last-Modified'] ) && function_exists( 'header_remove' ) )
    385             header_remove( 'Last-Modified' );
     385            @header_remove( 'Last-Modified' );
    386386
    387387        if ( $exit_required )
  • trunk/wp-includes/functions.php

    r22283 r22303  
    928928        @header("{$name}: {$field_value}");
    929929    if ( empty( $headers['Last-Modified'] ) && function_exists( 'header_remove' ) )
    930         header_remove( 'Last-Modified' );
     930        @header_remove( 'Last-Modified' );
    931931}
    932932
Note: See TracChangeset for help on using the changeset viewer.