avoid file fusion

This commit is contained in:
505030475
2023-06-19 16:57:11 +10:00
parent 951d5ec758
commit af7734dd35
3 changed files with 13 additions and 7 deletions

View File

@ -685,7 +685,7 @@ def 编译Latex(chatbot, history, main_file_original, main_file_modified, work_f
result_pdf = pj(work_folder_modified, f'{main_file_modified}.pdf')
if os.path.exists(pj(work_folder, '..', 'translation')):
shutil.copyfile(result_pdf, pj(work_folder, '..', 'translation', 'translate_zh.pdf'))
promote_file_to_downloadzone(result_pdf)
promote_file_to_downloadzone(result_pdf, chatbot)
return True # 成功啦
else:
if n_fix>=max_try: break