Do not do canonical redirects for unregistered feeds. fixes #16704 for trunk

git-svn-id: https://develop.svn.wordpress.org/trunk@17498 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2011-03-03 15:55:24 +00:00
parent b905438706
commit 0e84a66e49
1 changed files with 1 additions and 1 deletions

View File

@ -195,7 +195,7 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
}
$addl_path = '';
if ( is_feed() ) {
if ( is_feed() && in_array( get_query_var('feed'), $wp_rewrite->feeds ) ) {
$addl_path = !empty( $addl_path ) ? trailingslashit($addl_path) : '';
if ( get_query_var( 'withcomments' ) )
$addl_path .= 'comments/';