From 3f9c80a534c8b97daedd0979ec94834f0510d344 Mon Sep 17 00:00:00 2001 From: Dorian Merz <merz@ub.uni-leipzig.de> Date: Tue, 23 Mar 2021 13:49:51 +0100 Subject: [PATCH] refs #15982 [finc] JS Tree Renderer: fix undefined variable error for empty options --- module/finc/src/finc/Hierarchy/TreeRenderer/JSTree.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/finc/src/finc/Hierarchy/TreeRenderer/JSTree.php b/module/finc/src/finc/Hierarchy/TreeRenderer/JSTree.php index 27545e6589d..33089995cb3 100644 --- a/module/finc/src/finc/Hierarchy/TreeRenderer/JSTree.php +++ b/module/finc/src/finc/Hierarchy/TreeRenderer/JSTree.php @@ -99,7 +99,7 @@ class JSTree extends \VuFind\Hierarchy\TreeRenderer\JSTree ] ]; } - $cache[$route] = $this->router->fromRoute($route, $params, $options); + $cache[$route] = $this->router->fromRoute($route, $params, $options ?? []); } elseif ($route == 'parent') { // this is nearly the same as for collections // but links on the record view i.e. record route @@ -118,7 +118,7 @@ class JSTree extends \VuFind\Hierarchy\TreeRenderer\JSTree } // use route 'record' here to avoid linking to the // collection view - $cache[$route] = $this->router->fromRoute('record', $params, $options); + $cache[$route] = $this->router->fromRoute('record', $params, $options ?? []); } else { $tab = $this->treeRendererConfig->linkedTabDefault ?? 'Description'; $params = [ -- GitLab