Check file ending

This commit is contained in:
Lorenz Leitner 2019-03-15 09:15:42 +01:00
parent e0c30a34a0
commit 8b6ca5cbab

View File

@ -22,7 +22,7 @@ def get_image_dir_recursive(img_dir):
images = []
for path, subdirs, files in os.walk(img_dir):
for name in files:
print(os.path.join(path, name))
if name.lower().endswith(file_types):
images.append(os.path.join(path, name))
return images, current_wall