Ticket #20226: 20226.diff
File 20226.diff, 826 bytes (added by , 9 years ago) |
---|
-
src/wp-includes/class-wp.php
365 365 * @since 2.0.0 366 366 */ 367 367 public function send_headers() { 368 $headers = array( 'X-Pingback' => get_bloginfo('pingback_url'));368 $headers = array(); 369 369 $status = null; 370 370 $exit_required = false; 371 371 … … 595 595 596 596 // Never 404 for the admin, robots, or if we found posts. 597 597 if ( is_admin() || is_robots() || $wp_query->posts ) { 598 599 // Only set X-Pingback for single posts. 600 if ( is_single() ) { 601 $p = get_queried_object(); 602 if ( $p && pings_open( $p ) ) { 603 @header( 'X-Pingback: ' . get_bloginfo( 'pingback_url' ) ); 604 } 605 } 606 598 607 status_header( 200 ); 599 608 return; 600 609 }