[youtube] Fix lazy extractors (closes #28780)

pull/28842/head
Sergey M․ 4 years ago
parent dab83a2597
commit 32290307a4
No known key found for this signature in database
GPG Key ID: 2C393E0F18A9236D

@ -1219,6 +1219,9 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
@classmethod
def suitable(cls, url):
# Hack for lazy extractors until more generic solution is implemented
# (see #28780)
from .youtube import parse_qs
qs = parse_qs(url)
if qs.get('list', [None])[0]:
return False
@ -2910,6 +2913,9 @@ class YoutubePlaylistIE(InfoExtractor):
def suitable(cls, url):
if YoutubeTabIE.suitable(url):
return False
# Hack for lazy extractors until more generic solution is implemented
# (see #28780)
from .youtube import parse_qs
qs = parse_qs(url)
if qs.get('v', [None])[0]:
return False

Loading…
Cancel
Save