From 6bf021c9bd8faa9cba5151eaac5a9083cb28a83f Mon Sep 17 00:00:00 2001 From: Mario Santos <34552881+SantosGuillamot@users.noreply.github.com> Date: Thu, 10 Oct 2024 10:51:41 +0200 Subject: [PATCH] Check image `src` with falsy value (#66004) Co-authored-by: SantosGuillamot Co-authored-by: gziolo --- packages/block-library/src/image/index.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/block-library/src/image/index.php b/packages/block-library/src/image/index.php index 5d7815a1f2f3f..1a5fae7ce9cbb 100644 --- a/packages/block-library/src/image/index.php +++ b/packages/block-library/src/image/index.php @@ -24,7 +24,7 @@ function render_block_core_image( $attributes, $content, $block ) { $p = new WP_HTML_Tag_Processor( $content ); - if ( ! $p->next_tag( 'img' ) || null === $p->get_attribute( 'src' ) ) { + if ( ! $p->next_tag( 'img' ) || ! $p->get_attribute( 'src' ) ) { return ''; }