only return valid image

This commit is contained in:
j 2016-04-29 22:49:08 +02:00
parent 1348916ba1
commit 28897ff79d

View file

@ -119,7 +119,8 @@ class PosterCache(models.Model):
self.status = "invalid image" self.status = "invalid image"
self.image.delete() self.image.delete()
self.save() self.save()
return self.image if not failed:
return self.image
def get_poster_urls(m): def get_poster_urls(m):
def addPoster(url, site, site_id): def addPoster(url, site, site_id):