mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-24 05:36:56 +01:00
parent
b5ae35ee6d
commit
81bcd43a03
@ -290,7 +290,7 @@ def _real_extract(self, url):
|
|||||||
|
|
||||||
class HotStarSeriesIE(HotStarBaseIE):
|
class HotStarSeriesIE(HotStarBaseIE):
|
||||||
IE_NAME = 'hotstar:series'
|
IE_NAME = 'hotstar:series'
|
||||||
_VALID_URL = r'(?:https?://)(?:www\.)?hotstar\.com(?:/in)?/tv/[^/]+/(?P<id>\d+)'
|
_VALID_URL = r'(?P<url>(?:https?://)(?:www\.)?hotstar\.com(?:/in)?/tv/[^/]+/(?P<id>\d+))'
|
||||||
_TESTS = [{
|
_TESTS = [{
|
||||||
'url': 'https://www.hotstar.com/in/tv/radhakrishn/1260000646',
|
'url': 'https://www.hotstar.com/in/tv/radhakrishn/1260000646',
|
||||||
'info_dict': {
|
'info_dict': {
|
||||||
@ -312,7 +312,7 @@ class HotStarSeriesIE(HotStarBaseIE):
|
|||||||
}]
|
}]
|
||||||
|
|
||||||
def _real_extract(self, url):
|
def _real_extract(self, url):
|
||||||
series_id = self._match_id(url)
|
url, series_id = self._match_valid_url(url).groups()
|
||||||
headers = {
|
headers = {
|
||||||
'x-country-code': 'IN',
|
'x-country-code': 'IN',
|
||||||
'x-platform-code': 'PCTV',
|
'x-platform-code': 'PCTV',
|
||||||
@ -324,7 +324,7 @@ def _real_extract(self, url):
|
|||||||
video_id=series_id, headers=headers)
|
video_id=series_id, headers=headers)
|
||||||
entries = [
|
entries = [
|
||||||
self.url_result(
|
self.url_result(
|
||||||
'hotstar:episode:%d' % video['contentId'],
|
'%s/ignoreme/%d' % (url, video['contentId']),
|
||||||
ie=HotStarIE.ie_key(), video_id=video['contentId'])
|
ie=HotStarIE.ie_key(), video_id=video['contentId'])
|
||||||
for video in item_json['body']['results']['items']
|
for video in item_json['body']['results']['items']
|
||||||
if video.get('contentId')]
|
if video.get('contentId')]
|
||||||
|
Loading…
Reference in New Issue
Block a user