Skip to content

check if field layout element belongs to an enabled plugin#14219

Merged
brandonkelly merged 3 commits into5.0from
bugfix/check-field-layout-elements-againt-plugins
Jan 29, 2024
Merged

check if field layout element belongs to an enabled plugin#14219
brandonkelly merged 3 commits into5.0from
bugfix/check-field-layout-elements-againt-plugins

Conversation

@i-just
Copy link
Copy Markdown
Contributor

@i-just i-just commented Jan 26, 2024

Description

When adding a field layout element to a tab, check if it belongs to a disabled plugin, and if it does - don’t add it as an element.

Scenario:
Commerce plugin is installed, Addresses field layout is adjusted - from that point on, there’s a reference to UserAddressSettings (attribute commerceSettings) in the Address element field layout.
If you now disabled the Commerce plugin and try to edit or add an address (e.g. to your account) or try to edit the Address element field layout, you’ll get Invalid Configuration; Unable to locate message source for category 'commerce'. error.

This PR checks if the layout element belongs to a plugin and only adds it to the layout’s tab if it doesn’t or if the plugin it belongs to is enabled.

Related issues

n/a

@i-just i-just requested a review from brandonkelly January 26, 2024 15:41
@brandonkelly brandonkelly merged commit 2780a61 into 5.0 Jan 29, 2024
@brandonkelly brandonkelly deleted the bugfix/check-field-layout-elements-againt-plugins branch January 29, 2024 18:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants