1
0
Fork 0
mirror of https://github.com/ytdl-org/youtube-dl.git synced 2024-09-21 02:45:49 +00:00

Proposed changes

This commit is contained in:
Aniruddh Joshi 2021-10-15 10:02:17 +05:30 committed by GitHub
parent 30d8bbf6fa
commit 174b795485
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -9,6 +9,7 @@ from ..compat import compat_HTTPError
from ..utils import (
ExtractorError,
int_or_none,
try_get
)
@ -98,7 +99,7 @@ class SonyLIVIE(InfoExtractor):
title += ' - ' + episode
subtitles = {}
for subtitle in (content.get('subtitle') or []):
base_url = subtitle.get('subtitleUrl')
base_url = try_get(subtitle, lambda x: x['subtitleUrl'], compat_str)
if not base_url:
continue
lang_code = subtitle.get('subtitleLanguageName')