Skip to content

Commit

Permalink
Remove stale todo comment
Browse files Browse the repository at this point in the history
This comment mentions using a generator for breadcrumbs,
but breadcrumbs are no longer calculated on the fly, so
the comment is outdated.
  • Loading branch information
sirreal committed Dec 10, 2024
1 parent 329df9b commit 3ad6269
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/wp-includes/html-api/class-wp-html-processor.php
Original file line number Diff line number Diff line change
Expand Up @@ -1141,11 +1141,7 @@ public function step( $node_to_process = self::PROCESS_NEXT_NODE ): bool {
* Breadcrumbs start at the outermost parent and descend toward the matched element.
* They always include the entire path from the root HTML node to the matched element.
*
* @todo It could be more efficient to expose a generator-based version of this function
* to avoid creating the array copy on tag iteration. If this is done, it would likely
* be more useful to walk up the stack when yielding instead of starting at the top.
*
* Example
* Example:
*
* $processor = WP_HTML_Processor::create_fragment( '<p><strong><em><img></em></strong></p>' );
* $processor->next_tag( 'IMG' );
Expand Down

0 comments on commit 3ad6269

Please sign in to comment.