diff --git a/wp-admin/includes/class-wp-posts-list-table.php b/wp-admin/includes/class-wp-posts-list-table.php index 1e763f2ff3..0d4fdc2fd5 100644 --- a/wp-admin/includes/class-wp-posts-list-table.php +++ b/wp-admin/includes/class-wp-posts-list-table.php @@ -638,8 +638,9 @@ class WP_Posts_List_Table extends WP_List_Table { echo '
' . $locked_avatar . ' ' . $locked_text . "
\n"; } - if ( ! $this->hierarchical_display && 'excerpt' == $mode && current_user_can( 'read_post', $post->ID ) ) - the_excerpt(); + if ( ! $this->hierarchical_display && 'excerpt' == $mode && current_user_can( 'read_post', $post->ID ) ) { + echo esc_html( get_the_excerpt() ); + } $actions = array(); if ( $can_edit_post && 'trash' != $post->post_status ) {