Hey there,
Insert and update ops in hook_user() result in form_build_id being stored in the data field of the users table. I.e it's not unset before the data field is updated with all remaining fields in $edit. Patch to follow.
--
Sammy Spets
Synerger
http://synerger.com
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | formbuildid-usersave-v1-219105-11.patch | 984 bytes | Jorrit |
| #11 | formbuildid-usersave-v2-219105-11.patch | 996 bytes | Jorrit |
| #9 | bug-219105-usersave-v1.new_.patch | 814 bytes | Jorrit |
| #9 | bug-219105-usersave-v2.new_.patch | 824 bytes | Jorrit |
| #8 | bug-219105-usersave-v1.patch | 607 bytes | Jorrit |
Comments
Comment #1
sammys commentedHere is the patch.
Comment #2
bdragon commentedThe code from this section appears to have changed.
Comment #3
sammys commentedbdragon: In what way has it changed? The patch still applies...
Comment #4
sunBugs get fixed in HEAD first.
Comment #5
dave reidThis bug is actually fixed in 7.x. I tried editing and adding user accounts and there was no form_build_id variable in $user->data. Moving this back to 6.x.
Comment #6
cwgordon7 commentedThis patch still applies and fixes the problem.
Comment #8
Jorrit commentedI have updated the patch to apply to the latest version of drupal 6.x. I have two possible solutions. The first one is just ignoring the key form_build_id, but this leaves the existing value in the array. Given that Drupal 6 has been around for a long time, I suspect that many people have this value in their data field. So the second patch is slightly different: it will unset the form_build_id explicitly.
Comment #9
Jorrit commentedI have rerolled the patches against the latest -dev.
Comment #11
Jorrit commentedThanks to Eclipse for not creating git-compatible patches ... retry.
Comment #12
ufku commentedI think Heine's patch at #451770: Don't save form_build_id in data is more correct as the form_build_id comes from the profile form and it should be unset in the relevant submit handler.
Fixing the previously saved data should be done in a separate process, not in user_save.