ParentFormSelector Fatal

Created on 28 October 2024, 7 months ago

Problem/Motivation

If your site is using revisions for menu item links (for example for use with workspaces), then you can get into a situation:

TypeError: array_diff_key(): Argument #1 ($array) must be of type array, false given in array_diff_key() (line 302 of core/lib/Drupal/Core/Entity/EntityStorageBase.php).

Drupal\Core\Entity\EntityStorageBase->loadMultiple() (Line: 77)
Drupal\group_content_menu\GroupContentMenuParentFormSelector->getMenuOptions() (Line: 58)
Drupal\group_content_menu\GroupContentMenuParentFormSelector->parentSelectElement() (Line: 104)

Steps to reproduce

  • Enable revision support for menu item links
  • Edit any group content menu to add a link
  • Before saving the menu link select a parent link in the Parent link select at the top right of the form
  • Result in above error

Proposed resolution

See patch

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

3.0

Component

Code

Created by

heddn Nicaragua

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024