youtube-dl

Another place where youtube-dl lives on
git clone git://git.oshgnacknak.de/youtube-dl.git
Log | Files | Refs | README | LICENSE

commit ca74c90bf55cfb16f5eadc3a63e9389202ee80f5
parent 7cfc1e2a104977c41f6008885b36b96bcb2b146e
Author: Shai Coleman <shai.coleman@storyful.com>
Date:   Wed, 22 Jun 2016 12:52:15 +0100

Fix issue downloading facebook videos

youtube-dl expects the format items to be returned as a list,
but when there's only one item Facebook returns a dict instead,
this wraps the dict in a list if necessary

Diffstat:
Myoutube_dl/extractor/facebook.py | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/youtube_dl/extractor/facebook.py b/youtube_dl/extractor/facebook.py @@ -239,6 +239,8 @@ class FacebookIE(InfoExtractor): formats = [] for format_id, f in video_data.items(): + if f and isinstance(f, dict): + f = [f] if not f or not isinstance(f, list): continue for quality in ('sd', 'hd'):