Canonical / Query: After [36280] remove the unit tests which are no longer supported for 4.4.
This also removes the `is_feed()` code to avoid confusion - only pages & embeds will be redirected. See #35344 Built from https://develop.svn.wordpress.org/branches/4.4@36281 git-svn-id: http://core.svn.wordpress.org/branches/4.4@36248 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
26c5f0137f
commit
3a05448edf
|
@ -5027,9 +5027,7 @@ function wp_old_slug_redirect() {
|
||||||
|
|
||||||
$link = get_permalink( $id );
|
$link = get_permalink( $id );
|
||||||
|
|
||||||
if ( is_feed() ) {
|
if ( isset( $GLOBALS['wp_query']->query_vars['paged'] ) && $GLOBALS['wp_query']->query_vars['paged'] > 1 ) {
|
||||||
$link = user_trailingslashit( trailingslashit( $link ) . 'feed' );
|
|
||||||
} elseif ( isset( $GLOBALS['wp_query']->query_vars['paged'] ) && $GLOBALS['wp_query']->query_vars['paged'] > 1 ) {
|
|
||||||
$link = user_trailingslashit( trailingslashit( $link ) . 'page/' . $GLOBALS['wp_query']->query_vars['paged'] );
|
$link = user_trailingslashit( trailingslashit( $link ) . 'page/' . $GLOBALS['wp_query']->query_vars['paged'] );
|
||||||
} elseif( is_embed() ) {
|
} elseif( is_embed() ) {
|
||||||
$link = user_trailingslashit( trailingslashit( $link ) . 'embed' );
|
$link = user_trailingslashit( trailingslashit( $link ) . 'embed' );
|
||||||
|
|
Loading…
Reference in New Issue