Using authcache I it was showing an error on an foreach(element_children($element)) because attributes is null.

Although authcache could potentially sort this out, I think it's best practice not to populate a form element with a null value, but rather an empty array, and this kind of iteration of form elements are all over the place.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

hanoii created an issue. See original summary.

hanoii’s picture

hanoii’s picture

Issue summary: View changes
dench0’s picture

I'm have the same error.

TR’s picture

  • TR committed 0d0b614 on 7.x-3.x authored by hanoii
    Issue #2750151 by hanoii: Return empty array instead of null for...

  • TR committed 0dcd5d5 on 8.x-4.x authored by hanoii
    Issue #2750151 by hanoii: Return empty array instead of null for...
TR’s picture

Status: Needs review » Fixed

Thanks. Committed this fix to both 7.x-3.x and 8.x-4.x.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.