From a923a561ca37fd14d59262b8a910d037767468e5 Mon Sep 17 00:00:00 2001 From: gziolo Date: Fri, 18 Oct 2024 13:31:17 +0000 Subject: [PATCH] HTML API: Fix the position update after changing the modifiable text when length differs There was an edge case detected for updating the text placed without the wrapping HTML tag with `set_modifiable_text`. Props gziolo, jonsurrell. Fixes #62241. Built from https://develop.svn.wordpress.org/trunk@59250 git-svn-id: http://core.svn.wordpress.org/trunk@58642 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/html-api/class-wp-html-tag-processor.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/html-api/class-wp-html-tag-processor.php b/wp-includes/html-api/class-wp-html-tag-processor.php index 5e29fc7d15..e2632c80f6 100644 --- a/wp-includes/html-api/class-wp-html-tag-processor.php +++ b/wp-includes/html-api/class-wp-html-tag-processor.php @@ -2459,7 +2459,7 @@ class WP_HTML_Tag_Processor { } // Accumulate shift of the given pointer within this function call. - if ( $diff->start <= $shift_this_point ) { + if ( $diff->start < $shift_this_point ) { $accumulated_shift_for_given_point += $shift; } diff --git a/wp-includes/version.php b/wp-includes/version.php index 580e389ad2..1c233f0c45 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.7-beta3-59249'; +$wp_version = '6.7-beta3-59250'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.