From ec726ced190bd3553c0de6a14563940bc031b49a Mon Sep 17 00:00:00 2001 From: Tchama Date: Mon, 3 Aug 2020 12:34:11 +0200 Subject: [PATCH] sf4, fix error with index 'icon' in menu --- Routing/MenuComposer.php | 3 ++- Routing/MenuTwig.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Routing/MenuComposer.php b/Routing/MenuComposer.php index e03f61ba2..0bcee4c81 100644 --- a/Routing/MenuComposer.php +++ b/Routing/MenuComposer.php @@ -115,7 +115,8 @@ class MenuComposer 'order' => $order ]) ->setExtras([ - 'icon' => $route['icon'], + //'icon' => $route['icon'], + // sf4 check: commented to avoid error: `An exception has been thrown during the rendering of a template ("Notice: Undefined index: icon").` 'order' => $order ]) ; diff --git a/Routing/MenuTwig.php b/Routing/MenuTwig.php index 18cdf5c5d..fe233e205 100644 --- a/Routing/MenuTwig.php +++ b/Routing/MenuTwig.php @@ -82,7 +82,7 @@ class MenuTwig extends AbstractExtension implements ContainerAwareInterface * - layout: the layout. Absolute path needed (i.e.: ChillXyzBundle:section:foo.html.twig) * - activeRouteKey : the key active, will render the menu differently. * - * see https://redmine.champs-libres.coop/issues/179 for more informations + * @deprecated link: see https://redmine.champs-libres.coop/issues/179 for more informations * * @param string $menuId * @param mixed[] $params