The commerce_checkout_panes() function loads panes from the database and then invokes hook_commerce_checkout_pane_info(). Any panes returned from the hook that also exist in the database get a 'saved' key set to true. This saved key triggers an update rather than an insert. Because this module does not implement hook_commerce_checkout_pane_info(), but instead incorrectly inserts new fieldgroup panes in hook_commerce_checkout_pane_info_alter(), the fieldgroup panes are always inserted into the database as new records causing an error if it already exists.
Perhaps those who decided that hook_commerce_checkout_pane_info_alter() was necessary over hook_commerce_checkout_info() could chime in, but it seems to be working find using the latter.
Cheers,
Antoine
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 1308470-error_on_save_fieldgroup-3.patch | 1.62 KB | pcambra |
| #2 | error-on-update-1308470-2.patch | 1.7 KB | jantoine |
| #1 | error-on-update-1308470-1.patch | 1.7 KB | jantoine |
Comments
Comment #1
jantoine commentedPatch attached!
Cheers,
Antoine
Comment #2
jantoine commentedNew patch attached that respects existing whitespace characters.
Comment #3
pcambraI can confirm the error and the fix.
Here's the patch adapted to the right path and slightly changed.
Comment #4
pcambraCommitted.