Skip to content

Commit

Permalink
Editor: Avoid double escaping on value passed for attribute in HTML t…
Browse files Browse the repository at this point in the history
…ag processor

Fix for the Block Bindings processing.
See WordPress/wordpress-develop#5888 (comment).

Props: czapla, dmsnell, gziolo.


Built from https://develop.svn.wordpress.org/trunk@57561


git-svn-id: http://core.svn.wordpress.org/trunk@57062 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information
gziolo committed Feb 8, 2024
1 parent 0d374ff commit b89d86b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion wp-includes/class-wp-block.php
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ private function replace_html( string $block_content, string $attribute_name, $s
) ) {
return $block_content;
}
$amended_content->set_attribute( $block_type->attributes[ $attribute_name ]['attribute'], esc_attr( $source_value ) );
$amended_content->set_attribute( $block_type->attributes[ $attribute_name ]['attribute'], $source_value );
return $amended_content->get_updated_html();
break;

Expand Down
2 changes: 1 addition & 1 deletion wp-includes/version.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.5-alpha-57560';
$wp_version = '6.5-alpha-57561';

/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
Expand Down

0 comments on commit b89d86b

Please sign in to comment.