diff --git a/app/Helpers/Helper.php b/app/Helpers/Helper.php index 930185c..319bebe 100644 --- a/app/Helpers/Helper.php +++ b/app/Helpers/Helper.php @@ -726,7 +726,9 @@ function nestedWithData($items, $parent_id = null) if ($item->parent_id == $parent_id) { $name = $item->name ?? $item->title ?? $item->id; $r .= "
  • {$name}" . PHP_EOL; - $r .= nestedWithData($items, $item->id); + if ($item->hasAttribute('parent_id')) { + $r .= nestedWithData($items, $item->id); + } $r .= PHP_EOL . '
  • '; } }