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.
Using the metatag module and using available address field tokens for certain tags causes the below error.
Notice: Undefined index: format_handlers in addressfield_tokens() (line 223 ... of addressfield/addressfield.tokens.inc
Comment | File | Size | Author |
---|---|---|---|
#4 | addressfield-token_in_metatag_causing_undefined_error-2679014-4-do-not-test.patch | 860 bytes | sourabh.singhal |
Comments
Comment #2
yoftahe.addweb CreditAttribution: yoftahe.addweb at AddWeb Solution Pvt. Ltd. commentedCan you please provide the scenario to generate the same notice?
That would be helpful.
Comment #3
sourabh.singhal CreditAttribution: sourabh.singhal as a volunteer and at Faichi Solutions Pvt Ltd for Faichi Solutions Pvt Ltd commentedComment #4
sourabh.singhal CreditAttribution: sourabh.singhal as a volunteer and at Faichi Solutions Pvt Ltd for Faichi Solutions Pvt Ltd commentedHi 3dnathaniel,
Here is the patch attached for the same. Please review.
Thanks
Comment #5
AnybodyPatch in #4 leads to an undefined $format_handlers variable if the !empty() doesn't evaluate to true. This is not a proper fix.
Btw. this doesn't fix empty tokens in metatags FYI.