]> jfr.im git - yt-dlp.git/commitdiff
[ie/aenetworks] Rating should be optional for AP extraction (#9005)
authorAndrew Gibson <redacted>
Thu, 18 Jan 2024 21:18:04 +0000 (16:18 -0500)
committerGitHub <redacted>
Thu, 18 Jan 2024 21:18:04 +0000 (21:18 +0000)
Authored by: agibson-fl

yt_dlp/extractor/aenetworks.py

index 63a0532ef113f5dcb7ad3ac0ef1da0bd12c86d23..ab4b6c0ebc958ac05c4e61d6ae5914fd172bbda0 100644 (file)
@@ -93,7 +93,7 @@ def _extract_aetn_info(self, domain, filter_key, filter_value, url):
             resource = self._get_mvpd_resource(
                 requestor_id, theplatform_metadata['title'],
                 theplatform_metadata.get('AETN$PPL_pplProgramId') or theplatform_metadata.get('AETN$PPL_pplProgramId_OLD'),
-                theplatform_metadata['ratings'][0]['rating'])
+                traverse_obj(theplatform_metadata, ('ratings', 0, 'rating')))
             auth = self._extract_mvpd_auth(
                 url, video_id, requestor_id, resource)
         info.update(self._extract_aen_smil(media_url, video_id, auth))