Problem/Motivation

Steps to reproduce:

  1. install Drupal and Group
  2. create a Group type
  3. go to the available content configuration of your group type
  4. "configure" the group membership plugin
  5. change the Informational text and save

Expected result: the informational text (or any other change you made) has been saved
Current result: fatal error on save and it's now impossible to access that group type available content configuration page

Error displayed: Recoverable fatal error: Argument 1 passed to field_ui_entity_operation() must implement interface Drupal\Core\Entity\EntityInterface, null given, called in modules/contrib/group/src/Entity/Controller/GroupTypeController.php on line 233 and defined in field_ui_entity_operation() (line 140 of core/modules/field_ui/field_ui.module).

Proposed resolution

It seems that the link betweend the plugin and the group type is lost somehow during the save process. Fix it.

Remaining tasks

Figure out what happens exactly, fix it, review then commit.

User interface changes

None.

API changes

None.

Data model changes

None.

Comments

DuaelFr created an issue. See original summary.

duaelfr’s picture

(Do not expect a patch from me in the next days. I'm really busy for now. Thanks)

duaelfr’s picture

That's even worse than expected!
On the link betweend the plugin and the group type broken, All the pages related to this plugin are broken too.

Example on the group/GID/members page after having tried to change the informational text of the group membership plugin: Fatal error: Call to a member function getContentPlugin() on null in modules/contrib/group/src/Entity/Access/GroupContentAccessControlHandler.php on line 30

kristiaanvandeneynde’s picture

Oh wow, this never happened before. Having a look.

kristiaanvandeneynde’s picture

Status: Active » Fixed

Looks like the configuration form saves the following on the group type: group_type: null

This key will be no longer required as of #2764929: Export plugins with group content types, not group types, but for now I've commited a fix. Will release a beta2 for this.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.