1
0
Fork 0
mirror of https://codeberg.org/polarisfm/youtube-dl.git synced 2024-12-28 10:36:50 +00:00

[dramafever] Improve geo restriction detection and use geo bypass mechanism

This commit is contained in:
Sergey M․ 2017-02-04 18:51:16 +07:00 committed by Sergey M
parent 773f291dcb
commit d392005a79

View file

@ -116,8 +116,9 @@ class DramaFeverIE(DramaFeverBaseIE):
'http://www.dramafever.com/amp/episode/feed.json?guid=%s' % video_id)
except ExtractorError as e:
if isinstance(e.cause, compat_HTTPError):
raise ExtractorError(
'Currently unavailable in your country.', expected=True)
self.raise_geo_restricted(
msg='Currently unavailable in your country',
countries=['US', 'CA'])
raise
series_id, episode_number = video_id.split('.')