catch errors when creating thumbnails