[yandexmusic:track] Fix extraction (closes #26449, closes #26669, closes #26747, closes #26748, closes #26762)

This commit is contained in:
Sergey M․ 2020-11-29 22:15:51 +07:00
parent b449b73dcc
commit d6ce649f15
No known key found for this signature in database
GPG Key ID: 2C393E0F18A9236D
1 changed files with 1 additions and 2 deletions

View File

@ -109,8 +109,7 @@ class YandexMusicTrackIE(YandexMusicBaseIE):
'Downloading track location JSON', 'Downloading track location JSON',
query={'format': 'json'}) query={'format': 'json'})
key = hashlib.md5(('XGRlBW9FXlekgbPrRHuSiA' + fd_data['path'][1:] + fd_data['s']).encode('utf-8')).hexdigest() key = hashlib.md5(('XGRlBW9FXlekgbPrRHuSiA' + fd_data['path'][1:] + fd_data['s']).encode('utf-8')).hexdigest()
storage = track['storageDir'].split('.') f_url = 'http://%s/get-mp3/%s/%s?track-id=%s ' % (fd_data['host'], key, fd_data['ts'] + fd_data['path'], track['id'])
f_url = 'http://%s/get-mp3/%s/%s?track-id=%s ' % (fd_data['host'], key, fd_data['ts'] + fd_data['path'], storage[1])
thumbnail = None thumbnail = None
cover_uri = track.get('albums', [{}])[0].get('coverUri') cover_uri = track.get('albums', [{}])[0].get('coverUri')