mirror of
https://github.com/dylanaraps/pywal.git
synced 2025-07-11 03:25:11 +02:00
Merge 1ff36760d3
into 236aa48e74
This commit is contained in:
@ -79,7 +79,11 @@ def get_next_image(img_dir, recursive):
|
||||
image = images[next_index]
|
||||
|
||||
except IndexError:
|
||||
image = images[0]
|
||||
if images:
|
||||
image = images[0]
|
||||
else:
|
||||
logging.error("No images found in directory.")
|
||||
sys.exit(1)
|
||||
|
||||
return os.path.join(img_dir if not recursive else "", image)
|
||||
|
||||
|
Reference in New Issue
Block a user