Skip to content

Commit

Permalink
Merge pull request #7644 from Automattic/fix/deprecation-notice-on-re…
Browse files Browse the repository at this point in the history
…ports-screen

Fix deprecation notice when passing NULL to `wp_kses_post` on the reports screen
  • Loading branch information
m1r0 committed Jul 30, 2024
2 parents f4f5cae + fb74368 commit f16d959
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions changelog/fix-deprecation-notice-on-reports-screen
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fixed

Deprecation notice on the reports screen when using PHP 8.1
2 changes: 1 addition & 1 deletion includes/class-sensei-analysis-lesson-list-table.php
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ protected function get_row_data( $item ) {
$escaped_column_data = array();

foreach ( $column_data as $key => $data ) {
$escaped_column_data[ $key ] = wp_kses_post( $data );
$escaped_column_data[ $key ] = $data ? wp_kses_post( $data ) : $data;
}

return $escaped_column_data;
Expand Down

0 comments on commit f16d959

Please sign in to comment.