From d6bfc44a16ca61ad6d5e3c9c1299e22d0cfeeb2e Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Thu, 8 Feb 2018 10:56:55 +0000 Subject: [PATCH] Comments: Avoid extra tabs in a textarea in `WP_Comments_List_Table::column_comment()`. Props chetan200891, jrf. Fixes #43252. git-svn-id: https://develop.svn.wordpress.org/trunk@42670 602fd350-edb4-49c9-b593-d223f7449a82 --- .../includes/class-wp-comments-list-table.php | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/src/wp-admin/includes/class-wp-comments-list-table.php b/src/wp-admin/includes/class-wp-comments-list-table.php index e64086d525..09e59b9134 100644 --- a/src/wp-admin/includes/class-wp-comments-list-table.php +++ b/src/wp-admin/includes/class-wp-comments-list-table.php @@ -685,19 +685,17 @@ if ( ( 'spam' === $comment_status || 'trash' === $comment_status ) && current_us } comment_text( $comment ); + if ( $this->user_can ) { + /** This filter is documented in wp-admin/includes/comment.php */ + $comment_content = apply_filters( 'comment_edit_pre', $comment->comment_content ); ?>