Review main Merged

96890[BUGFIX] Skip subpage check for language menu items

Oli Bartsch CR +2 V +2 Easy +16 −3 updated 10/28/26, 18:26

Commit message

Since AbstractMenuContentObject::getMenuItems() is used by the
LanguageMenuProcessor, hasSubpages is calculated for every language
menu item by calling isSubMenu(). All of these items represent the
current page, so each call loads every subpage of the current page
with all columns. On pages with a very large number of subpages this
exhausts the available memory.

Language menus never evaluated this state before, because their items
carry an explicit ITEM_STATE. getMenuItems() therefore no longer calls
isSubMenu() for items of a language menu and omits the hasSubpages
key for them, as language menus did before TYPO3 v14.1.

Review

  • Code review CR +2 Done
    • Oli Bartsch +2
    • Wouter Wolters +1
    • Benni Mack +1
  • Verified V +2 Done
    • Oli Bartsch +2
    • Wouter Wolters +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 1

Files 2

Review log 810

  1. Oli Bartsch uploaded patch set 1 10/19/26, 20:55

  2. core-ci voted on patch set 1 V +1 10/19/26, 21:04 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111722

  3. Georg Ringer commented on patch set 1 CR -1 10/23/26, 05:42

    AbstractMenuContentObject.php:1936

    IMO we should only add the key hasSubpages if we do the check. Otherwise integrators debug the menu item and think that they can actually do checks on it - for whatever reason. what do you think?
  4. Oli Bartsch uploaded patch set 2 CR -1 V +1 10/24/26, 20:25

  5. Oli Bartsch commented on patch set 2 10/24/26, 20:26

    AbstractMenuContentObject.php:1936 Reply

    yes, a hardcoded 0 is misleading. I droped the key for language menu items and makes it optional in the array shape. The test keeps hasSubpages in the filter list, so it asserts the key is absent.
  6. core-ci voted on patch set 2 V +1 10/24/26, 20:35 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/112435

  7. Benni Mack voted on patch set 2 CR +1 V +1 10/28/26, 12:56

  8. Wouter Wolters voted on patch set 2 CR +1 V +1 10/28/26, 17:30

  9. Oli Bartsch voted on patch set 2 CR +2 V +2 10/28/26, 18:26

  10. Oli Bartsch merged patch set 3 10/28/26, 18:26