Posts: In wp_ajax_inline_save()
, do not apply level for non-hierarchical post types.
Props Offereins. Fixes #35010. git-svn-id: https://develop.svn.wordpress.org/trunk@37913 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
9008030f1e
commit
3715a70613
@ -1689,6 +1689,7 @@ function wp_ajax_inline_save() {
|
||||
$mode = $_POST['post_view'] === 'excerpt' ? 'excerpt' : 'list';
|
||||
|
||||
$level = 0;
|
||||
if ( is_post_type_hierarchical( $wp_list_table->screen->post_type ) ) {
|
||||
$request_post = array( get_post( $_POST['post_ID'] ) );
|
||||
$parent = $request_post[0]->post_parent;
|
||||
|
||||
@ -1697,6 +1698,7 @@ function wp_ajax_inline_save() {
|
||||
$parent = $parent_post->post_parent;
|
||||
$level++;
|
||||
}
|
||||
}
|
||||
|
||||
$wp_list_table->display_rows( array( get_post( $_POST['post_ID'] ) ), $level );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user