From 615206139e9b3c7c216a33ca33756b3d41cdbc05 Mon Sep 17 00:00:00 2001 From: frxz751113 <156018267+frxz751113@users.noreply.github.com> Date: Thu, 15 Aug 2024 19:53:05 +0800 Subject: [PATCH] =?UTF-8?q?Update=20=E5=9C=A8=E7=BA=BFV4=E6=BA=90=E4=BC=98?= =?UTF-8?q?=E9=80=89.py?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- py/在线V4源优选.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/py/在线V4源优选.py b/py/在线V4源优选.py index 9473bc6..bca8d3a 100644 --- a/py/在线V4源优选.py +++ b/py/在线V4源优选.py @@ -27,13 +27,13 @@ open('源.txt','wb').write(r.content) with open('源.txt', 'r', encoding='utf-8') as file: lines = file.readlines() - filtered_lines = [] - for line in lines: - if ',' in line: - if 'epg' not in line and 'mitv' not in line and 'udp' not in line and 'rtp' not in line and '[' not in line \ +filtered_lines = [] +for line in lines: + if ',' in line: + if 'epg' not in line and 'mitv' not in line and 'udp' not in line and 'rtp' not in line and '[' not in line \ and 'P2p' not in line and 'p2p' not in line and 'p3p' not in line and 'P2P' not in line and 'P3p' not in line and 'P3P' not in line: filtered_lines.append(line) - return filtered_lines +return filtered_lines with open('源.txt', 'w', encoding='utf-8') as output_file: output_file.writelines(filtered_lines)