diff --git a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
index 4c662a25566f9e52bcbab9783b2388a734f9d6c3..8f46a54f70727d5f8ea0b26cfa58afee203d59a6 100644
--- a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
+++ b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
@@ -5597,6 +5597,7 @@ class ContentObjectRenderer implements LoggerAwareInterface
                         // Call recursively, if the id is not in prevID_array:
                         if (!in_array($next_id, $prevId_array)) {
                             $theList = array_merge(
+                                $theList,
                                 GeneralUtility::intExplode(
                                     ',',
                                     $this->getTreeList(
@@ -5610,8 +5611,7 @@ class ContentObjectRenderer implements LoggerAwareInterface
                                         $recursionLevel + 1
                                     ),
                                     true
-                                ),
-                                $theList
+                                )
                             );
                         }
                     }