Use wp_revisions_enabled(). props ethitter. fixes #24525.
git-svn-id: https://develop.svn.wordpress.org/trunk@24425 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
ebcf303db6
commit
71fcaad59b
@ -26,7 +26,7 @@ case 'restore' :
|
||||
break;
|
||||
|
||||
// Revisions disabled (previously checked autosavegs && ! wp_is_post_autosave( $revision ))
|
||||
if ( ( ! WP_POST_REVISIONS || ! post_type_supports( $post->post_type, 'revisions' ) ) ) {
|
||||
if ( ! wp_revisions_enabled( $post ) ) {
|
||||
$redirect = 'edit.php?post_type=' . $post->post_type;
|
||||
break;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user