pops param try_look when logged in.

This commit is contained in:
grqx_wsl 2024-07-26 10:04:18 +12:00
parent 29a5968278
commit b01183f904

View File

@ -166,6 +166,8 @@ def _sign_wbi(self, params, video_id):
def _download_playinfo(self, bvid, cid, headers=None, **kwargs): def _download_playinfo(self, bvid, cid, headers=None, **kwargs):
params = {'bvid': bvid, 'cid': cid, 'fnval': 4048, **kwargs} params = {'bvid': bvid, 'cid': cid, 'fnval': 4048, **kwargs}
if self.is_logged_in:
params.pop('try_look', None)
return self._download_json( return self._download_json(
'https://api.bilibili.com/x/player/wbi/playurl', bvid, 'https://api.bilibili.com/x/player/wbi/playurl', bvid,
query=self._sign_wbi(params, bvid), headers=headers, query=self._sign_wbi(params, bvid), headers=headers,