mirror of
https://github.com/KnugiHK/WhatsApp-Chat-Exporter.git
synced 2026-03-26 07:45:26 +00:00
Exit if no json is found
This commit is contained in:
@@ -268,6 +268,10 @@ def incremental_merge(source_dir: str, target_dir: str, media_dir: str, pretty_p
|
|||||||
media_dir (str): The path to the media directory.
|
media_dir (str): The path to the media directory.
|
||||||
"""
|
"""
|
||||||
json_files = [f for f in os.listdir(source_dir) if f.endswith('.json')]
|
json_files = [f for f in os.listdir(source_dir) if f.endswith('.json')]
|
||||||
|
if not json_files:
|
||||||
|
print("No JSON files found in the source directory.")
|
||||||
|
return
|
||||||
|
|
||||||
print("JSON files found:", json_files)
|
print("JSON files found:", json_files)
|
||||||
|
|
||||||
for json_file in json_files:
|
for json_file in json_files:
|
||||||
|
|||||||
Reference in New Issue
Block a user