diff -r 7b1b88e27a20 -r 48c4eec2b7e6 wp/wp-includes/html-api/class-wp-html-token.php --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/wp/wp-includes/html-api/class-wp-html-token.php Fri Sep 05 18:40:08 2025 +0200 @@ -0,0 +1,106 @@ +bookmark_name = $bookmark_name; + $this->node_name = $node_name; + $this->has_self_closing_flag = $has_self_closing_flag; + $this->on_destroy = $on_destroy; + } + + /** + * Destructor. + * + * @since 6.4.0 + */ + public function __destruct() { + if ( is_callable( $this->on_destroy ) ) { + call_user_func( $this->on_destroy, $this->bookmark_name ); + } + } + + /** + * Wakeup magic method. + * + * @since 6.4.2 + */ + public function __wakeup() { + throw new \LogicException( __CLASS__ . ' should never be unserialized' ); + } +}