I'm not sure if this is how you'd like to handle it but presently location moduel is throwing errors when a node is saved using node_save() and the $node->locations array doesn't exist. Instead of requiring this attribute i short circuited the switch in hook_nodeapi('insert/update') and "return"ed if the array was empty. See attached patch rolled against DRUPAL-5
| Comment | File | Size | Author |
|---|---|---|---|
| confirmLocationPresence.patch | 731 bytes | michaelfavia |
Comments
Comment #1
sasconsul commentedI think, I have seen a similar problem when I add a node through the MailHandler. Here is the error message:
The patch fixes the problem only for the 'insert' and 'update' $op cases. MailHandler makes the error appear for the 'valdiate' case.
Comment #2
raspberryman commentedSubscribing
Comment #3
markusH commentedCool. The same problem appears if you
first: created a biography node using bio.module and attach location info to this content type.
and then: configured bio module to display some fields (which can't be location fields) on the user registration form
Fixed the problem for me.
Is there a chance this fix goes into location module for good?
Comment #4
michaelfavia commentedtentatively marking rtbc after confirmations above. please downgrade if desired or commit at leisure.
Comment #5
bdragon commentedThe reason I haven't committed this yet is this is one of the sections that are currently in the middle of being rewritten.
Comment #6
bdragon commentedFixed in HEAD earlier.
Thanks guys.
Comment #7
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.