Fix for images
Improve thumb handling