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.
The loading of field data should emulate file_field_load(), which sets the item value to NULL if a file fails to load. The current behavior will cause the FALSE returned from file_load() to be casted to array(FALSE)
which messes up file field formatters.
Comment | File | Size | Author |
---|---|---|---|
#2 | 2774857-do-not-cast-unloaded-files.patch | 877 bytes | Dave Reid |
Comments
Comment #2
Dave ReidComment #4
Sneakyvv CreditAttribution: Sneakyvv at Calibrate for Government of Flanders commentedSeems a valid point. The code looks good, so I've committed it to dev. Thanks for the patch!