From 89a2081614b6db61168212309a75c54c93d4b9f4 Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Mon, 3 Jun 2019 12:46:02 +0200 Subject: [PATCH] Always display the second level categories for articles Closes #2886 --- .../install/files/lib/data/category/CategoryNode.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wcfsetup/install/files/lib/data/category/CategoryNode.class.php b/wcfsetup/install/files/lib/data/category/CategoryNode.class.php index 4cadf7c0a7..5d9c46a376 100644 --- a/wcfsetup/install/files/lib/data/category/CategoryNode.class.php +++ b/wcfsetup/install/files/lib/data/category/CategoryNode.class.php @@ -169,8 +169,8 @@ class CategoryNode extends DatabaseObjectDecorator implements \RecursiveIterator * @since 5.2 */ public function isVisibleInNestedList(AbstractDecoratedCategory $activeCategory = null) { - if (!$this->getParentCategory()) { - // level 1 is always visible + if (!$this->getParentCategory() || ($this->getParentCategory() && !$this->getParentCategory()->getParentCategory())) { + // level 1 & 2 are always visible return true; } -- 2.20.1