Describe your bug or feature request.
I just upgraded to Commerce 3.2.0 from 2.40 and tried using the new OrderItemsWidget.
I'm getting a WSOD on the order edit form, with the following error:
TypeError: array_merge(): Argument #2 must be of type array, null given in array_merge() (line 297 of modules/contrib/commerce/modules/order/src/Plugin/Field/FieldWidget/OrderItemsWidget.php).
For some reason on this project $form['submit'] exists and has just a #weight, no #submit key, causing the array_merge call to fail.
On another project $form['submit'] is NULL, not really sure what's actually causing the key to be set in one case and not the other.
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | 3552867-7.patch | 1.61 KB | jsacksick |
Issue fork commerce-3552867
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
jsacksick commentedComment #3
tbkot commentedHere is the patch with the updated logic to add a custom submit callback to the main entity action
Comment #5
tbkot commentedFixing the typo in the previous patch
Comment #6
jsacksick commentedComment #7
jsacksick commentedComment #8
jsacksick commentedWent with the approach from the MR.