Problem/Motivation

When enabling or disabling entity types/bundles in the Mobile Native Share configuration form (/admin/config/services/mobile-native-share), the changes are not immediately reflected on the "Manage display" tabs of the respective content types.
The pseudo-field (extra field) provided by the module only appears or disappears after a manual full cache rebuild (`drush cr`), because the field definition discovery cache (entity_extra_field_info) is not invalidated upon saving the module settings.

Proposed resolution

Inject the entity_field.manager service into MobileNativeShareSettings and call $this->entityFieldManager->clearCachedFieldDefinitions(); inside the submitForm() method. This will clear the field definitions cache seamlessly without impacting frontend performance.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

fromme created an issue. See original summary.

fromme’s picture

Status: Active » Fixed

Fixed, released in 1.2.1

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

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