clear all cached sizes

This commit is contained in:
j 2016-01-16 10:47:52 +05:30
commit b899768130
4 changed files with 39 additions and 22 deletions

View file

@ -384,8 +384,7 @@ class Node(Thread):
content = fileobj.read()
key = 'preview:' + item.id
icons[key] = content
for resolution in (128, 256, 512):
del icons['preview:%s' % resolution]
icons.clear('preview:%s:'%item.id)
return True
except:
logger.debug('preview download failed %s', url, exc_info=1)