Skip to content

Normalise removal of fields from project config field layouts #11054

Closed Answered by brandonkelly
rynpsc asked this question in Ideas
Discussion options

You must be logged in to vote

As an aside is the path being provided to $projectConfig->remove correct? The paths contain referecnes to .fields., should that be .elements.?

Doh… looks like we forgot to update these methods when we refactored field layouts in Craft 3.5, so they’ve been pointless ever since then.

I explored the idea of centralizing the pruning of deleted fields from field layouts when looking into #11333, but unfortunately there’s just not a clean & reliable way to do it, without risking unexpected data deletion.

In the end, I decided it’s best to just let the field layouts continue to reference the deleted fields, and to stop logging a warning when instantiating a field layout with one.

I’ve also dep…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@brandonkelly
Comment options

Answer selected by brandonkelly
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Ideas
Labels
None yet
2 participants