0
0
Fork 0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-11-23 02:25:11 +00:00

[kuwo] Check for georestriction

This commit is contained in:
Yen Chi Hsuan 2016-02-04 01:26:25 +08:00
parent c84d3a557d
commit 58be922079

View file

@ -31,6 +31,10 @@ def _get_formats(self, song_id):
(file_format['ext'], file_format.get('br', ''), song_id),
song_id, note='Download %s url info' % file_format['format'],
)
if song_url == 'IPDeny':
raise ExtractorError('This song is blocked in this region', expected=True)
if song_url.startswith('http://') or song_url.startswith('https://'):
formats.append({
'url': song_url,