Problem/Motivation
This can be a method on FormState, preventing code from having to call out to the form builder.
Proposed resolution
Remove the method from FormBuilder
Leave the deprecated form_set_value() function in place, it will be removed by an issue in #2205673: [META] Remove all @deprecated functions marked "remove before 8.0"
Remaining tasks
User interface changes
API changes
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | form_state-2313397-6.patch | 9.76 KB | tim.plunkett |
| #3 | interdiff.txt | 960 bytes | tim.plunkett |
| #3 | form_state-2313397-3.patch | 9.92 KB | tim.plunkett |
| #1 | form_state-2313397-1.patch | 8.78 KB | tim.plunkett |
Comments
Comment #1
tim.plunkettComment #2
jibranI haven't seen any test code for this method. I think we should add some quick unit test for it.
Are we still using it in
FormBuilde? Perhaps we can remove it.Comment #3
tim.plunkettWe are still using NestedArray in FormBuilder for other things.
Here's a test.
Comment #4
jibranThank you RTBC.
Comment #5
alexpottNeeds a reroll plus can someone work out which CRs need updating.
Comment #6
tim.plunkettHere's the reroll, will find the CR next.
Comment #7
tim.plunkettHmm, there were no CRs pointing to FormBuilderInterface::setValue(), and none about form_set_value(), which still exists.
So this either needs one now, or we write one when we kill the actual functions.
Comment #8
jibranThanks for the reroll. Back to RTBC.
Comment #9
tim.plunkettPosted https://www.drupal.org/node/2315243 now instead of later.
Comment #10
alexpottI deleted https://www.drupal.org/node/2315243 and added this to https://www.drupal.org/node/2121003
Comment #11
webchickWell that's definitely much nicer.
Committed and pushed to 8.x. Thanks!
Comment #13
tim.plunkettThanks!