From ca1da4aeb7aee7ca18e471cd689df63efc693d9e Mon Sep 17 00:00:00 2001 From: wbt5 Date: Sat, 25 Jul 2020 16:52:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=96=97=E9=B1=BC=E7=9B=B4?= =?UTF-8?q?=E6=92=AD=E6=BA=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- douyu.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/douyu.py b/douyu.py index 511a4c0..a7eb3f8 100644 --- a/douyu.py +++ b/douyu.py @@ -101,8 +101,8 @@ def get_sign_url(post_v, rid, tt, ub9): if 'mix=1' in real_url: result1 = mix_room(rid) else: - pattern1 = r'live/(\d{1,8}[0-9a-zA-Z]+)_?[\d]{0,4}/playlist' - result1 = re.findall(pattern1, real_url, re.I)[0] + pattern = r'/(\d{1,8}[0-9a-zA-Z]+)_?[\d]{0,4}.m3u8' + result1 = re.search(pattern, real_url).group(1) else: result1 = 0 return result1