projects
/
youtube-dl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improve geo bypass mechanism
[youtube-dl]
/
youtube_dl
/
extractor
/
nrk.py
diff --git
a/youtube_dl/extractor/nrk.py
b/youtube_dl/extractor/nrk.py
index 78ece33e12ab869f746991137c7b7b456eb08c64..13af9ed1f7395e178774036ea8ae68dab62c8570 100644
(file)
--- a/
youtube_dl/extractor/nrk.py
+++ b/
youtube_dl/extractor/nrk.py
@@
-14,6
+14,7
@@
from ..utils import (
class NRKBaseIE(InfoExtractor):
class NRKBaseIE(InfoExtractor):
+ _GEO_COUNTRIES = ['NO']
def _real_extract(self, url):
video_id = self._match_id(url)
def _real_extract(self, url):
video_id = self._match_id(url)
@@
-93,7
+94,8
@@
class NRKBaseIE(InfoExtractor):
# Can be ProgramIsGeoBlocked or ChannelIsGeoBlocked*
if 'IsGeoBlocked' in message_type:
self.raise_geo_restricted(
# Can be ProgramIsGeoBlocked or ChannelIsGeoBlocked*
if 'IsGeoBlocked' in message_type:
self.raise_geo_restricted(
- msg=MESSAGES.get('ProgramIsGeoBlocked'), countries=['NO'])
+ msg=MESSAGES.get('ProgramIsGeoBlocked'),
+ countries=self._GEO_COUNTRIES)
raise ExtractorError(
'%s said: %s' % (self.IE_NAME, MESSAGES.get(
message_type, message_type)),
raise ExtractorError(
'%s said: %s' % (self.IE_NAME, MESSAGES.get(
message_type, message_type)),