From 9a3fdbbddc53e15867daaaed421039651b28bd54 Mon Sep 17 00:00:00 2001 From: Blanc Ray <9410067+BlancRay@users.noreply.github.com> Date: Fri, 17 Jul 2020 10:38:20 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=99=8E=E7=89=99=E7=9B=B4?= =?UTF-8?q?=E6=92=AD=E5=BD=95=E5=83=8F=E5=9C=B0=E5=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 虎牙直播录像地址缺少https --- huya.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/huya.py b/huya.py index 49c26d8..5e4f71b 100644 --- a/huya.py +++ b/huya.py @@ -42,7 +42,7 @@ def get_real_url(room_id): liveLineUrl = re.findall(r'liveLineUrl = "([\s\S]*?)";', response)[0] if liveLineUrl: if 'replay' in liveLineUrl: - return '直播录像:' + liveLineUrl + return '直播录像:https:' + liveLineUrl else: liveLineUrl = live(liveLineUrl) real_url = ["https:" + liveLineUrl, "https:" + re.sub(r'_\d{4}.m3u8', '.m3u8', liveLineUrl)] @@ -56,4 +56,4 @@ def get_real_url(room_id): rid = input('请输入虎牙房间号:\n') real_url = get_real_url(rid) print('该直播间源地址为:') -print(real_url) \ No newline at end of file +print(real_url)