From d9871d5f692a258e621c0766239c70a4c58d1f2a Mon Sep 17 00:00:00 2001 From: Dave Smith Date: Wed, 21 Sep 2022 19:01:56 +0100 Subject: [PATCH] href only if url is not empty --- .../block-library/src/navigation-submenu/index.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/block-library/src/navigation-submenu/index.php b/packages/block-library/src/navigation-submenu/index.php index 3c41fb340cafb..6ff4899575b27 100644 --- a/packages/block-library/src/navigation-submenu/index.php +++ b/packages/block-library/src/navigation-submenu/index.php @@ -183,7 +183,16 @@ function render_block_core_navigation_submenu( $attributes, $content, $block ) { if ( ! $open_on_click ) { $item_url = isset( $attributes['url'] ) ? $attributes['url'] : ''; // Start appending HTML attributes to anchor tag. - $html .= '