Fix yield photo should only happen when not exception.

master
voussoir 2020-12-30 12:30:18 -08:00
parent 023c540dbf
commit 017633331b
1 changed files with 1 additions and 1 deletions

View File

@ -58,9 +58,9 @@ def get_photos_by_glob(pattern):
for file in files: for file in files:
try: try:
photo = photodb.get_photo_by_path(file) photo = photodb.get_photo_by_path(file)
yield photo
except etiquette.exceptions.NoSuchPhoto: except etiquette.exceptions.NoSuchPhoto:
pass pass
yield photo
def get_photos_by_globs(patterns): def get_photos_by_globs(patterns):
for pattern in patterns: for pattern in patterns: