mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-14 20:38:11 -05:00
[ie/twitter] Remove cookies migration workaround (#11392)
Closes #11338 Authored by: bashonly
This commit is contained in:
parent
d569a88452
commit
76802f4613
1 changed files with 0 additions and 8 deletions
|
@ -150,14 +150,6 @@ def _search_dimensions_in_video_url(a_format, video_url):
|
||||||
def is_logged_in(self):
|
def is_logged_in(self):
|
||||||
return bool(self._get_cookies(self._API_BASE).get('auth_token'))
|
return bool(self._get_cookies(self._API_BASE).get('auth_token'))
|
||||||
|
|
||||||
# XXX: Temporary workaround until twitter.com => x.com migration is completed
|
|
||||||
def _real_initialize(self):
|
|
||||||
if self.is_logged_in or not self._get_cookies('https://twitter.com/').get('auth_token'):
|
|
||||||
return
|
|
||||||
# User has not yet been migrated to x.com and has passed twitter.com cookies
|
|
||||||
TwitterBaseIE._API_BASE = 'https://api.twitter.com/1.1/'
|
|
||||||
TwitterBaseIE._GRAPHQL_API_BASE = 'https://twitter.com/i/api/graphql/'
|
|
||||||
|
|
||||||
@functools.cached_property
|
@functools.cached_property
|
||||||
def _selected_api(self):
|
def _selected_api(self):
|
||||||
return self._configuration_arg('api', ['graphql'], ie_key='Twitter')[0]
|
return self._configuration_arg('api', ['graphql'], ie_key='Twitter')[0]
|
||||||
|
|
Loading…
Reference in a new issue