From 27ed8e6db52267f863b305a7cabac3a74915573d Mon Sep 17 00:00:00 2001 From: buttle Date: Fri, 25 Mar 2022 11:17:14 +0100 Subject: [PATCH] does not render empty menu --- view/common/wordpress-menu.phtml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/view/common/wordpress-menu.phtml b/view/common/wordpress-menu.phtml index 248f45c..54ae007 100644 --- a/view/common/wordpress-menu.phtml +++ b/view/common/wordpress-menu.phtml @@ -54,6 +54,8 @@ function render_menu($items, $level_id) { echo '' . PHP_EOL; } -render_menu($items, 0); +if (count($items[0]) > 0) { + render_menu($items, 0); +} ?>