Make WordPress Core

Changeset 59361


Ignore:
Timestamp:
11/06/2024 12:03:05 PM (3 months ago)
Author:
SergeyBiryukov
Message:

Editor: Correct the number of arguments for WP_HTML_Tag_Processor::get_tag().

This resolves an issue with ::get_tag() being called in WP_Block::replace_html() with an extra argument, as the method accepts no arguments.

Follow-up to [57514].

Props justlevine, mukesh27.
See #52217.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-block.php

    r59095 r59361  
    375375                foreach ( $selectors as $selector ) {
    376376                    // If the parent tag, or any of its children, matches the selector, replace the HTML.
    377                     if ( strcasecmp( $block_reader->get_tag( $selector ), $selector ) === 0 || $block_reader->next_tag(
     377                    if ( strcasecmp( $block_reader->get_tag(), $selector ) === 0 || $block_reader->next_tag(
    378378                        array(
    379379                            'tag_name' => $selector,
Note: See TracChangeset for help on using the changeset viewer.