mirror of
https://codeberg.org/polarisfm/youtube-dl
synced 2024-11-23 00:54:31 +01:00
[Minds] Use negative lookahead in channel IE to ignore invalid names
This commit is contained in:
parent
b0c19812d5
commit
7719ef4681
@ -133,13 +133,11 @@ class MindsActivityIE(InfoExtractor):
|
||||
|
||||
|
||||
class MindsChannelIE(InfoExtractor):
|
||||
_VALID_URL = r'https?://(?:www\.)?minds\.com/(?P<id>[^/]+)'
|
||||
_VALID_URL = r'https?://(?:www\.)?minds\.com/(?!newsfeed|media|api)(?P<id>[^/]+)'
|
||||
|
||||
def _real_extract(self, url):
|
||||
channel_name = self._match_id(url)
|
||||
api_url = 'https://www.minds.com/api/v1/channel/%s' % channel_name
|
||||
if channel_name == 'media':
|
||||
return self.url_result(url, ie='Minds')
|
||||
token = self._get_cookies(url).get('XSRF-TOKEN')
|
||||
headers = {
|
||||
'authority': 'www.minds.com',
|
||||
|
Loading…
Reference in New Issue
Block a user