Closed (fixed)
Project:
Varnish purger
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
2 Jan 2018 at 11:11 UTC
Updated:
17 Jul 2018 at 10:39 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
ChrisBee commentedComment #3
mikelutzWhy was this issue closed as works as designed with no comment? This is causing me headaches as well. varnish_image_purge_entity_update() collects all the image fields on an entity, and accesses element 0 without checking to see if the image field is empty or not, throwing a notice in the array index access attempt, and a warning when calling File::load(NULL).
In addition, if I'm reading this correctly, if the image field has a cardinality > 1, only the first image in the field is queued for cache removal, and all the rest are ignored. This should be looping through all the images in the image field, if available and queueing them all (or none if the field is empty)
Comment #4
mikelutzThis patch checks to make sure the image field is not empty, and purges all images in a field, not just the first one.
Comment #6
misc commentedThanks for the patch @mikelutz, I have added it to the latest dev, and it will be in the new release later today.