By claudiu.cristea on
Change record status:
Published (View all published change records)
Project:
Introduced in branch:
9.2.x
Introduced in version:
9.2.0
Issue links:
Description:
Entity route parameters are accepting a new bundle definition property of type array. By defining such a property, the param conversion will be limited to the specified bundles:
example.route:
path: foo/{example}
options:
parameters:
example:
type: entity:node
bundle:
- article
- news
With the above example, the {example} parameter will be converted to a node only if the value is referring to node of type 'article' or 'news'.
The _entity_bundles route requirement is deprecated.
Using this new syntax over _entity_bundles allows your code to return a HTTP code 404 when there is no match, instead of _entity_bundles issuing a HTTP code 403.
Impacts:
Module developers
Themers
Site templates, recipes and distribution developers