From: W. Trevor King Date: Sat, 21 Feb 2015 19:55:57 +0000 (-0800) Subject: gallery.py: Fix is_video to use VIDEO_EXTENSIONS X-Git-Url: http://git.tremily.us/?p=blog.git;a=commitdiff_plain;h=e1c4530223ad481fdb2d88b283052a1b2bcac0b5 gallery.py: Fix is_video to use VIDEO_EXTENSIONS Avoid: HTML page URLs must end with a slash when the script doesn't recognize a video URL as a cacheable page. It looks like this bug snuck in way back in ebd0292d (Allow gallery.py to serve original images, 2012-08-25). --- diff --git a/posts/gallery/gallery.py b/posts/gallery/gallery.py index 3634690..8ea08d8 100755 --- a/posts/gallery/gallery.py +++ b/posts/gallery/gallery.py @@ -1,6 +1,6 @@ #!/usr/bin/env python # -# Copyright (C) 2010-2013 W. Trevor King +# Copyright (C) 2010-2015 W. Trevor King # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -142,7 +142,7 @@ def is_image(filename): return False def is_video(filename): - for extension in IMAGE_EXTENSIONS: + for extension in VIDEO_EXTENSIONS: if filename.lower().endswith(extension): return True return False