Skip to content

Commit 5adcd24

Browse files
committed
f
1 parent b1af5ce commit 5adcd24

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

scripts/translator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ def translate_directory(language, source_path, dest_path, model, num_threads, cl
425425
translate_files = None # Need to initialize it here to avoid error
426426
if args.file_paths:
427427
# Translate only the indicated file
428-
translate_files = [f.strip() for f in args.file_paths.split(',') if f]
428+
translate_files = list(set([f.strip() for f in args.file_paths.split(',') if f]))
429429
for file_path in translate_files:
430430
#with tqdm(total=len(all_markdown_files), desc="Translating Files") as pbar:
431431
with concurrent.futures.ThreadPoolExecutor(max_workers=num_threads) as executor:

0 commit comments

Comments
 (0)