103103 * associative array. {@see static::get_last_json_error()} for when this fails.
104104 * - {@see self::is_html()} indicates if the token is a span of HTML which might
105105 * be top-level freeform content or a block’s inner HTML.
106- * - {@see self::get_html_content_and_advance ()} returns the span of HTML.
106+ * - {@see self::get_html_content ()} returns the span of HTML.
107107 * - {@see self::get_span()} for the byte offset and length into the input document
108108 * representing the token.
109109 *
@@ -1256,7 +1256,7 @@ public function get_depth(): int {
12561256 */
12571257 public function extract_block (): ?array {
12581258 if ( $ this ->is_html () ) {
1259- $ chunk = $ this ->get_html_content_and_advance ();
1259+ $ chunk = $ this ->get_html_content ();
12601260
12611261 return array (
12621262 'blockName ' => null ,
@@ -1278,7 +1278,7 @@ public function extract_block(): ?array {
12781278 $ depth = $ this ->get_depth ();
12791279 while ( $ this ->next_token () && $ this ->get_depth () > $ depth ) {
12801280 if ( $ this ->is_html () ) {
1281- $ chunk = $ this ->get_html_content_and_advance ();
1281+ $ chunk = $ this ->get_html_content ();
12821282 $ block ['innerHTML ' ] .= $ chunk ;
12831283 $ block ['innerContent ' ][] = $ chunk ;
12841284 continue ;
@@ -1639,14 +1639,13 @@ public function is_non_whitespace_html(): bool {
16391639 }
16401640
16411641 /**
1642- * Returns the string content of an HTML span and advances the parser so that
1643- * the next delimiter will be after the HTML span.
1642+ * Returns the string content of a matched HTML span, or `null` otherwise.
16441643 *
16451644 * @since 6.9.0
16461645 *
1647- * @return string|null HTML content, or `null` if not currently matched on HTML.
1646+ * @return string|null Raw HTML content, or `null` if not currently matched on HTML.
16481647 */
1649- public function get_html_content_and_advance (): ?string {
1648+ public function get_html_content (): ?string {
16501649 if ( ! $ this ->is_html () ) {
16511650 return null ;
16521651 }
0 commit comments