Replace a redundant ! is_preview() check with a more appropriate one.
fixes #20496. Built from https://develop.svn.wordpress.org/trunk@28928 git-svn-id: http://core.svn.wordpress.org/trunk@28726 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
e1db9240b7
commit
ca650bd79c
|
@ -78,8 +78,8 @@ function redirect_canonical( $requested_url = null, $do_redirect = true ) {
|
||||||
if ( !isset($redirect['query']) )
|
if ( !isset($redirect['query']) )
|
||||||
$redirect['query'] = '';
|
$redirect['query'] = '';
|
||||||
|
|
||||||
// If its not a preview then remove it from URL
|
// It's not a preview, so remove it from URL
|
||||||
if ( ! is_preview() ) {
|
if ( get_query_var( 'preview' ) ) {
|
||||||
$redirect['query'] = remove_query_arg( 'preview', $redirect['query'] );
|
$redirect['query'] = remove_query_arg( 'preview', $redirect['query'] );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue