]> git.bitcoin.ninja Git - youtube-dl/commitdiff
[facebook] Fix typo and break when found video_data (Closes #10048)
authorSergey M․ <dstftw@gmail.com>
Sat, 9 Jul 2016 14:25:07 +0000 (21:25 +0700)
committerSergey M․ <dstftw@gmail.com>
Sat, 9 Jul 2016 14:25:07 +0000 (21:25 +0700)
youtube_dl/extractor/facebook.py

index 0d43acc4ac7ff0162bdcc95471ccdb2376c0f7f2..cdb093262a00387386a0a3243554f46386276733 100644 (file)
@@ -231,11 +231,13 @@ class FacebookIE(InfoExtractor):
                     continue
                 if isinstance(f, dict):
                     f = [f]
-                if isinstance(f, list):
+                if not isinstance(f, list):
                     continue
                 if f[0].get('video_id') == video_id:
                     video_data = video_data_candidate
                     break
+            if video_data:
+                break
 
         def video_data_list2dict(video_data):
             ret = {}