|
@@ -7,8 +7,9 @@ def imgs_from_dir2pdf(source_dir_path, target_dir_path):
|
|
dirname = source_dir_path
|
|
dirname = source_dir_path
|
|
imgs = []
|
|
imgs = []
|
|
for fname in os.listdir(dirname):
|
|
for fname in os.listdir(dirname):
|
|
- if not fname.endswith(".jpg" or ".png"):
|
|
|
|
- continue
|
|
|
|
|
|
+ if not fname.endswith(".jpg"):
|
|
|
|
+ if not fname.endswith(".png"):
|
|
|
|
+ continue
|
|
path = os.path.join(dirname, fname)
|
|
path = os.path.join(dirname, fname)
|
|
if os.path.isdir(path):
|
|
if os.path.isdir(path):
|
|
continue
|
|
continue
|