Problem/Motivation
Issue #1427158: Use field_collection_field_formatter_prepare_view to increase performance by 50% introduced a new bug. When the field value equals the entity id, then it overwrites it. Specifically L1005 in https://git.drupalcode.org/project/field_collection/blame/7.x-1.x/field_....
If I have 3 fields collection with ids [1][1, 5, 8]. When #1 has a field with values [1,2,3] then it replaces it. [1][1,5,8] becomes [1][1,2,3]
https://git.drupalcode.org/project/field_collection/blame/7.x-1.x/field_... does a for loop of the items. So it does [1], [2], [3], when it should do [1], [5], [8].
Comment | File | Size | Author |
---|---|---|---|
#2 | stop_working-3091188-1.patch | 2.05 KB | iStryker |
|
Comments
Comment #2
iStryker CreditAttribution: iStryker commentedAttached is a patch that fixes it. I need someone to review this to make sure the logic of loading the field data still works.
FYI - commenting out line 1005 also works.
Comment #4
ram4nd CreditAttribution: ram4nd as a volunteer commentedComment #6
Liam Morland