mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-03 23:25:06 +00:00
[nrk] Improve geo restriction detection
This commit is contained in:
parent
7e08e2cab0
commit
50913b8241
1 changed files with 3 additions and 2 deletions
|
@ -93,8 +93,9 @@ def video_id_and_title(idx):
|
||||||
}]
|
}]
|
||||||
|
|
||||||
if not entries:
|
if not entries:
|
||||||
message_type = data.get('messageType')
|
message_type = data.get('messageType', '')
|
||||||
if message_type == 'ProgramIsGeoBlocked' and not self._faked_ip:
|
# Can be ProgramIsGeoBlocked or ChannelIsGeoBlocked*
|
||||||
|
if 'IsGeoBlocked' in message_type and not self._faked_ip:
|
||||||
self.report_warning(
|
self.report_warning(
|
||||||
'Video is geo restricted, trying to fake IP')
|
'Video is geo restricted, trying to fake IP')
|
||||||
self._fake_ip()
|
self._fake_ip()
|
||||||
|
|
Loading…
Reference in a new issue