dont fail on resize

This commit is contained in:
j 2016-01-24 16:04:18 +05:30
parent 35c0c02d16
commit cfb6913ef6

View file

@ -128,7 +128,10 @@ class Handler(http.server.SimpleHTTPRequestHandler):
return return
if preview: if preview:
from item.icons import get_icon_sync from item.icons import get_icon_sync
data = get_icon_sync(id, 'preview', 512) try:
data = get_icon_sync(id, 'preview', 512)
except:
data = None
if data: if data:
self.send_response(200, 'ok') self.send_response(200, 'ok')
self.send_header('Content-type', 'image/jpg') self.send_header('Content-type', 'image/jpg')