Use wp_revisions_enabled(). props ethitter. fixes #24525.
git-svn-id: http://core.svn.wordpress.org/trunk@24425 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b2fc7d1b8b
commit
4263262f40
|
@ -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…
Reference in New Issue