[ie/9gag] Support browser impersonation (#13678)
Closes #10837 Authored by: bashonly
This commit is contained in:
parent
805519bfaa
commit
0b359b184d
1 changed files with 2 additions and 3 deletions
|
|
@ -1,6 +1,5 @@
|
|||
from .common import InfoExtractor
|
||||
from ..utils import (
|
||||
ExtractorError,
|
||||
determine_ext,
|
||||
int_or_none,
|
||||
traverse_obj,
|
||||
|
|
@ -61,10 +60,10 @@ class NineGagIE(InfoExtractor):
|
|||
post = self._download_json(
|
||||
'https://9gag.com/v1/post', post_id, query={
|
||||
'id': post_id,
|
||||
})['data']['post']
|
||||
}, impersonate=True)['data']['post']
|
||||
|
||||
if post.get('type') != 'Animated':
|
||||
raise ExtractorError(
|
||||
self.raise_no_formats(
|
||||
'The given url does not contain a video',
|
||||
expected=True)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue