aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor/facebook.py
diff options
context:
space:
mode:
authorYen Chi Hsuan <yan12125@gmail.com>2016-02-16 09:07:38 +0800
committerYen Chi Hsuan <yan12125@gmail.com>2016-02-16 09:07:38 +0800
commitcb64ccc71531fd7491f65ad12fa1d68ac5de70e1 (patch)
tree57024ffebb2b669e48515df44e9a86467dfad7e5 /youtube_dl/extractor/facebook.py
parentf66a3c7bc2c675b0a053c6cfab6f755cb9f5bbda (diff)
[facebook] Improve error handling (#8572)
Diffstat (limited to 'youtube_dl/extractor/facebook.py')
-rw-r--r--youtube_dl/extractor/facebook.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/youtube_dl/extractor/facebook.py b/youtube_dl/extractor/facebook.py
index ed237f081..0a9a5ca71 100644
--- a/youtube_dl/extractor/facebook.py
+++ b/youtube_dl/extractor/facebook.py
@@ -186,7 +186,7 @@ class FacebookIE(InfoExtractor):
if not video_data:
server_js_data = self._parse_json(self._search_regex(
r'handleServerJS\(({.+})\);', webpage, 'server js data'), video_id)
- for item in server_js_data['instances']:
+ for item in server_js_data.get('instances', []):
if item[1][0] == 'VideoConfig':
video_data = video_data_list2dict(item[2][0]['videoData'])
break