allow handling thumbnail errors

This commit is contained in:
Robin Appelman 2015-08-28 20:14:48 +02:00
parent 0f6df2e0b6
commit c6060f53cd
1 changed files with 4 additions and 1 deletions

View File

@ -132,7 +132,10 @@
y: 75,
callback: function(previewUrl) {
$iconDiv.css('background-image', 'url("' + previewUrl + '")');
}
},
error: function() {
this.$el.find('.thumbnailContainer').removeClass('image'); //fall back to regular view
}.bind(this)
});
} else {
// TODO: special icons / shared / external