def download(self):
info = grab_json(API_URL + "/programs/" + self.video_key)
+ if "playlist" not in info:
+ return False
video_url = self.find_hls_url(info["playlist"])
token, token_hostname= self.get_auth_details()
video_url = self.add_auth_token_to_url(video_url, token, token_hostname)
def fill_children(self):
info = grab_json(self.url)
for key in ["carousels", "collections", "index"]:
- for collection_list in info[key]:
+ for collection_list in info.get(key, None):
if isinstance(collection_list, dict):
for ep_info in collection_list.get("episodes", []):
self.add_series(ep_info)