mirror of
https://github.com/wbt5/real-url.git
synced 2025-06-17 08:25:25 +08:00
Update twitch.py
Client-ID 改成 clientId
This commit is contained in:
parent
8b7635d2fc
commit
4b2c4d5258
@ -23,7 +23,7 @@ class Twitch:
|
|||||||
def get_client_id(self):
|
def get_client_id(self):
|
||||||
try:
|
try:
|
||||||
res = self.s.get(f'https://www.twitch.tv/{self.rid}').text
|
res = self.s.get(f'https://www.twitch.tv/{self.rid}').text
|
||||||
client_id = re.search(r'"Client-ID":"(.*?)"', res).group(1)
|
client_id = re.search(r'clientId="(.*?)"', res).group(1)
|
||||||
return client_id
|
return client_id
|
||||||
except requests.exceptions.ConnectionError:
|
except requests.exceptions.ConnectionError:
|
||||||
raise Exception('ConnectionError')
|
raise Exception('ConnectionError')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user