Skip to content

[6.x] Fix addon settings blueprint cache collision with field settings blueprint#14509

Merged
jasonvarga merged 1 commit into6.xfrom
addon-settings-blueprints
Apr 17, 2026
Merged

[6.x] Fix addon settings blueprint cache collision with field settings blueprint#14509
jasonvarga merged 1 commit into6.xfrom
addon-settings-blueprints

Conversation

@duncanmcclean
Copy link
Copy Markdown
Member

This pull request fixes an issue where using addon settings inside a fieldtype's configFieldItems method would cause the addon settings blueprint fields to be returned rather than the field's own settings.

This was happening because Addon::settingsBlueprint() created a Blueprint::make() with no handle. When a fieldtype's configFieldItems accessed addon settings, the applyBlueprintDefaults method (added in #14384) would resolve the addon's settings blueprint, caching its contents and fields under a Blink key based on an empty handle. Later, when the field settings blueprint (also created with Blueprint::make() and no handle) tried to resolve its own fields, it would get the cached addon settings blueprint fields instead.

This PR fixes it by giving addon settings blueprints a unique handle (addons.{slug}), preventing the Blink cache collision.

Fixes #14472
Caused by #14384

@jasonvarga jasonvarga merged commit b99ae25 into 6.x Apr 17, 2026
18 checks passed
@jasonvarga jasonvarga deleted the addon-settings-blueprints branch April 17, 2026 17:28
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.

Using an addon's settings in a fieldtype's configFieldItems breaks the CP since 6.11

2 participants