We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent de06d0b commit b21ed57Copy full SHA for b21ed57
src/wp-includes/html-api/class-wp-html-processor.php
@@ -379,7 +379,23 @@ public function set_inner_html( ?string $html ) {
379
return false;
380
}
381
382
- $html = $html ? $this->normalize( $html ) : '';
+ if ( null === $html ) {
383
+ $html = '';
384
+ }
385
+ if ( '' !== $html ) {
386
+ $fragment_parser = $this->spawn_fragment_parser( $html );
387
+ if (
388
+ null === $fragment_parser
389
+ ) {
390
+ return false;
391
392
+
393
+ try {
394
+ $html = $fragment_parser->serialize();
395
+ } catch ( Exception $e ) {
396
397
398
399
400
// @todo apply modifications if there are any???
401
0 commit comments