Closed WHITE-developer closed 2 years ago
Yes, that's an oversight on my part, that exception should be handled. Not sure if it makes sense to use fallbackImage there, it's probably better to just return false
, and let the fallbackImage kick in when trying to do a transform on the asset? Of course, that would mean that if your fallback image is an animated image, it wouldn't detect that, but... I think maybe we can assume that a fallback image should be a static image?
Now I'm thinking about it a bit more, yes, a static fallback image is perfect. Could get a bit messy otherwise :joy:. So returning false, or just don't trow the error on line 169 and 190, would do the trick.
I'm submitting a...
Description
We use S3 for our image storage. In the frontend we check if the image is an animated gif with
craft.imager.isAnimated(img)
. When the image doesn't exist on S3 anymore but Craft still knows the image, you get an error "Could not open create the stream" cause, yeah, it doesn't exist anymore. We thought maybe anfallbackImage
could help us, but it seems it doesn't do a check for it thereDisplayed errors, stack trace, relevant logs
Additional info