diff options
author | Sergey M․ <dstftw@gmail.com> | 2016-03-21 22:24:42 +0600 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2016-03-21 22:24:42 +0600 |
commit | ff5873b72de16854ae8d506d5648148a54828243 (patch) | |
tree | fbd8bed1eeddbe1046d9fd84f3d23368e9c92753 /youtube_dl/extractor | |
parent | 065c4b27bfc4488758b357e023e9b6b1679c9641 (diff) |
[motherless] Detect friends only videos
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r-- | youtube_dl/extractor/motherless.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/youtube_dl/extractor/motherless.py b/youtube_dl/extractor/motherless.py index ad04b12cd..5e1a8a71a 100644 --- a/youtube_dl/extractor/motherless.py +++ b/youtube_dl/extractor/motherless.py @@ -69,6 +69,9 @@ class MotherlessIE(InfoExtractor): ">The page you're looking for cannot be found.<")): raise ExtractorError('Video %s does not exist' % video_id, expected=True) + if '>The content you are trying to view is for friends only.' in webpage: + raise ExtractorError('Video %s is for friends only' % video_id, expected=True) + title = self._html_search_regex( r'id="view-upload-title">\s+([^<]+)<', webpage, 'title') video_url = self._html_search_regex( |