Commit dc786724 by murtaugh

better naming for THUMBNAIL_EXTS

parent ef0f4a50
Showing with 2 additions and 2 deletions
......@@ -30,7 +30,7 @@ EXT["image/svg+xml"] = "svg"
EXT["application/svg+xml"] = "svg"
EXT["application/svg"] = "svg"
EXT["application/pdf"] = "pdf"
IMAGE_EXT = set(("png", "jpg", "gif", "pdf", "svg"))
THUMBNAIL_EXTS = set(("png", "jpg", "gif", "pdf", "svg"))
DL_VIMEO_FORMAT = "http-360p"
DATETIME_STRF = "%Y-%m-%d %H:%M:%S"
......@@ -200,7 +200,7 @@ class PageWeb (object):
description = "{0} {1}".format(link, now.strftime("%Y/%m/%d"))
wikifile = upload_file_to_wiki(self.wiki, filename, None, description, phpuploader=phpuploader, user=user)
gallery.append(wikifile.name)
if thumbnail == None and ext in IMAGE_EXT:
if thumbnail == None and ext in THUMBNAIL_EXTS:
thumbnail = wikifile.page_title
if not thumbnail:
thumbnail = ""
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment