Be less verbose when erroring out in do_feed() for an invalid feed template. fixes #24874.
git-svn-id: https://develop.svn.wordpress.org/trunk@25190 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
dc3df4d410
commit
ee2baada7b
@ -1005,10 +1005,8 @@ function do_feed() {
|
||||
$feed = get_default_feed();
|
||||
|
||||
$hook = 'do_feed_' . $feed;
|
||||
if ( !has_action($hook) ) {
|
||||
$message = sprintf( __( 'ERROR: %s is not a valid feed template.' ), esc_html($feed));
|
||||
wp_die( $message, '', array( 'response' => 404 ) );
|
||||
}
|
||||
if ( ! has_action( $hook ) )
|
||||
wp_die( __( 'ERROR: This is not a valid feed template.' ), '', array( 'response' => 404 ) );
|
||||
|
||||
do_action( $hook, $wp_query->is_comment_feed );
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user