# Child category level 3 not constains in child array

**URL:** https://forum.shopware.com/t/child-category-level-3-not-constains-in-child-array/86473
**Category:** Shopware 6 (English)
**Created:** [25. März 2021 um 11:37 UTC](https://forum.shopware.com/t/child-category-level-3-not-constains-in-child-array/86473 "2021-03-25T11:37:31Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Pawel](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@Pawel](https://forum.shopware.com/u/Pawel)
#### Post date: [25. März 2021 um 11:37 UTC](https://forum.shopware.com/t/child-category-level-3-not-constains-in-child-array/86473/1 "2021-03-25T11:37:31Z")

</div>

referring to the topic

> [@Shopware 6 Menü zeigt nicht alle Ebenen an](https://forum.shopware.com/t/shopware-6-menu-zeigt-nicht-alle-ebenen-an/63741/5):
>
> Scheinbar wird das in der Klasse NavigationLoader festgelegt: /\*\*&nbsp;@var&nbsp;CategoryCollection&nbsp;$firstTwoLevels&nbsp;\*/ $firstTwoLevels&nbsp;=&nbsp;$this-\>categoryRepository-\>search($criteria,&nbsp;$context)-\>getEntities(); return&nbsp;$firstTwoLevels;

I have set $ depth to 3 and it works fine, but how can it be done according to the art for v6.5.1?
