diff options
author | Remita Amine <remitamine@gmail.com> | 2016-08-16 16:19:36 +0100 |
---|---|---|
committer | Remita Amine <remitamine@gmail.com> | 2016-08-16 16:22:34 +0100 |
commit | 11f502fac145b4592f47c025ee8317fe44020db0 (patch) | |
tree | 6d1beeb0ff374dd40fc2b17ea58c8f1a5f42d7ce /youtube_dl/extractor/theplatform.py | |
parent | 98affc1a482ab41466c76cfded41949c4db58f67 (diff) |
[theplatform] extract subtitles with multiple formats from the metadata
Diffstat (limited to 'youtube_dl/extractor/theplatform.py')
-rw-r--r-- | youtube_dl/extractor/theplatform.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/youtube_dl/extractor/theplatform.py b/youtube_dl/extractor/theplatform.py index eda899497..23067e8c6 100644 --- a/youtube_dl/extractor/theplatform.py +++ b/youtube_dl/extractor/theplatform.py @@ -73,10 +73,10 @@ class ThePlatformBaseIE(OnceIE): if isinstance(captions, list): for caption in captions: lang, src, mime = caption.get('lang', 'en'), caption.get('src'), caption.get('type') - subtitles[lang] = [{ + subtitles.setdefault(lang, []).append({ 'ext': mimetype2ext(mime), 'url': src, - }] + }) return { 'title': info['title'], |