Added generating of thumbnails