WordPress.org

Make WordPress Core

Opened 3 months ago

Closed 5 weeks ago

Last modified 5 weeks ago

#53597 closed defect (bug) (fixed)

Correct the documentation for the `wp_kses_allowed_html` filter

Reported by: johnbillion Owned by: johnbillion
Milestone: 5.9 Priority: normal
Severity: normal Version:
Component: Security Keywords: has-patch
Focuses: docs Cc:

Description

The documentation for the wp_kses_allowed_html filter mistakenly documents the first parameter as the context instead of as the array of allowed HTML tags. This is due to the fact that the $context parameter can be used as either, and the filter falls within the condition where $context is actually an array of HTML tags.

Improving the variable names passed to the canonical instance of the filter helps clarify this. The six further instances of the filter immediately below it all reference the canonical documentation.

Change History (3)

This ticket was mentioned in PR #1469 on WordPress/wordpress-develop by johnbillion.


3 months ago

  • Keywords has-patch added; needs-patch removed

#2 @johnbillion
5 weeks ago

  • Owner set to johnbillion
  • Resolution set to fixed
  • Status changed from new to closed

In 51675:

Security: Correct the inline docs for the wp_kses_allowed_html filter.

Props peterwilsoncc

Fixes #53597

Note: See TracTickets for help on using tickets.