Hi @goatman1,
Thanks for your message.
Verifying all files and checking if they are animated would be too burdensome, so I didn’t implement this solution. If there is a better way, I will try to implement it.
At this moment, I have a different solution for you. Please try to delete all regenerated images at this time.
If you have more of them, try using a prefix for such images (e.q. animated-). Then add the following filter to your code (using the correct file name):
add_filter('webpc_attachment_paths', function($paths)
{
if (!isset($paths[0]) || !preg_match('/\/animated-(.*?)\.png/', $paths[0])) {
return $paths;
} else {
return [];
}
});
And then regenerate your images. Does this solution help you?