1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-02-14 02:25:36 +08:00

[vgtv] Improve geo restriction detection

This commit is contained in:
Sergey M․ 2017-02-04 18:55:31 +07:00
parent 24a6b35bb1
commit b8dcacce27
No known key found for this signature in database
GPG Key ID: 2C393E0F18A9236D

View File

@ -14,6 +14,7 @@ from ..utils import (
class VGTVIE(XstreamIE):
IE_DESC = 'VGTV, BTTV, FTV, Aftenposten and Aftonbladet'
_BYPASS_GEO = False
_HOST_TO_APPNAME = {
'vgtv.no': 'vgtv',
@ -217,7 +218,7 @@ class VGTVIE(XstreamIE):
properties = try_get(
data, lambda x: x['streamConfiguration']['properties'], list)
if properties and 'geoblocked' in properties:
raise self.raise_geo_restricted()
raise self.raise_geo_restricted(countries=['NO'])
self._sort_formats(info['formats'])