Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
After editing a profile type, I received the following error:
Undefined property: ProfileType::$delta in homebox_forms() (line 203 of /var/aegir/platforms/drupal-7.0-essentials/sites/all/modules/contrib/homebox/homebox.module).
Running D7 on Ubuntu 10.04 (Lucid).
Thanks
Comment | File | Size | Author |
---|---|---|---|
#4 | homebox-undefined_propert_module_delta-1167978-4.patch | 727 bytes | rv0 |
Comments
Comment #1
brianV CreditAttribution: brianV commentedCan't reproduce. Anyone else?
Comment #2
wesnick CreditAttribution: wesnick commentedI have seen this error on a site I am building. Basically any use of the entity API will potentially cause this error.
In the implementation of hook_forms on lines 195-205 in homebox.module, there is a simple conditional within a switch:
So essentially, any form that passes an object as the second argument will return TRUE for this statement. Almost all Entity API framework forms pass 3 variables: $entity_type, $entity, $op, so they will return true for this, but they don't have a delta.
I am not sure what is going on here, but if you are trying to catch homebox block form implementations, might have to add a
conditional to make sure we are not getting any old form generated with drupal.
Comment #3
wesnick CreditAttribution: wesnick commentedOK, I get it now, you are checking to find any block forms on the homebox page that may have submit buttons, so as to add ajax action to them.
I am using this line as a patch:
very long and ugly, but seems to work.
Comment #4
rv0 CreditAttribution: rv0 commentedPatch by JaakkoL in #1088242: Undefined index: module in homebox_build() (line 360 of homebox.module) works for this
I post it here for clarity
Comment #5
mzwyssig CreditAttribution: mzwyssig commented#4 works for me as well. Will this get committed ?
Comment #6
drummCommitted.