Merge pull request #3 from timi137137/main

修复短链无法识别的问题
This commit is contained in:
苏晓晴 2024-06-24 08:04:45 +08:00 committed by GitHub
commit 29b47c5337
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -28,6 +28,9 @@ def parse_cookie(text: str):
# 输入id选项
def ids(ids):
if '163cn.tv' in ids:
response = requests.get(ids, allow_redirects=False)
ids = response.headers.get('Location')
if 'music.163.com' in ids:
index = ids.find('id=') + 3
ids = ids[index:].split('&')[0]