Don't attempt old slug redirect for multi-post_type queries. Props aaroncampbell. see #16949

git-svn-id: https://develop.svn.wordpress.org/trunk@18330 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2011-06-23 16:35:34 +00:00
parent 35ebb06f22
commit bb75e13b17
1 changed files with 6 additions and 0 deletions

View File

@ -3493,6 +3493,12 @@ function wp_old_slug_redirect() {
else
$post_type = 'post';
if ( is_array( $post_type ) ) {
if ( count( $post_type ) > 1 )
return;
$post_type = array_shift( $post_type );
}
// Do not attempt redirect for hierarchical post types
if ( is_post_type_hierarchical( $post_type ) )
return;