Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid forcing to define the choices_as_values option when using choic…
…e_loader When using the choice loader, choices are ignored entirely. Forcing the dev to add the choices_as_values just to avoid the deprecation warning (and then to remove the option again at some point in 3.x due to deprecation) is a bad developer experience.
- Loading branch information
fb4d8de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It causes cyclic dependency problem in projects when 'choice_loader' closure makes internal call of offsetGet('choices') like sonata-project does.
Now we cannot use $options['options'] inside choices_loader closure.
I think it's more critical than deprecation message (however I also hate it).
fb4d8de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@andreyserdjuk this deserve an issue !
fb4d8de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Created, #22354.