Made get_image_files() exclude hidden files (leading . in filename).

This commit is contained in:
Simon Fransson 2014-10-17 00:06:25 +02:00
parent bdb904ea08
commit 253a9d7af6
1 changed files with 1 additions and 1 deletions

View File

@ -98,7 +98,7 @@ def get_image_files(user=None, path=''):
return
for filename in storage_list[STORAGE_FILES]:
if os.path.splitext(filename)[0].endswith('_thumb'):
if os.path.splitext(filename)[0].endswith('_thumb') or os.path.basename(filename).startswith('.'):
continue
filename = os.path.join(browse_path, filename)
yield filename