summaryrefslogtreecommitdiff
path: root/db.py
diff options
context:
space:
mode:
Diffstat (limited to 'db.py')
-rw-r--r--db.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/db.py b/db.py
index eaf5f13..8cadb6b 100644
--- a/db.py
+++ b/db.py
@@ -67,7 +67,7 @@ class File(Base):
return self.get_mime_type().startswith('image')
def image_html(self):
- return u'<a href="{root}f/{hash}{ext}" title="{filename}"><img src="{root}t/{hash}" alt="{filename}" /></a>'.format(
+ return u'<a href="{root}f/{hash}{ext}" title="{filename}"><img src="{root}t/{hash}" alt="{filename}" onerror="thumb_onerror(this)" /></a>'.format(
root = settings.virtual_root, hash = self.hash, filename = self.filename, ext = os.path.splitext(self.filename)[1])
Base.metadata.create_all()