Update iptv-cv2-check.py

This commit is contained in:
frxz751113
2024-08-11 18:40:32 +08:00
committed by GitHub
parent 1f1ea7dbf9
commit def8e4b625
+1 -2
View File
@@ -620,8 +620,7 @@ def check_and_write_file(input_file, output_file, keywords):
out_file.write(line)
extracted_lines = True
# 如果没有提取到任何关键词,则不保留输出文件
#if not extracted_lines:
if file_size < 800:
if not extracted_lines:
os.remove(output_file) # 删除空的输出文件
print(f"未提取到关键词,{output_file} 已被删除。")
else: