[flipagram] Add extractor

This commit is contained in:
Déstin Reed 2016-06-25 19:01:47 +02:00 committed by Sergey M․
parent 89e2fff2b7
commit 3fee7f636c
No known key found for this signature in database
GPG key ID: 2C393E0F18A9236D
3 changed files with 111 additions and 0 deletions

View file

@ -837,6 +837,13 @@ class InfoExtractor(object):
'title': unescapeHTML(json_ld.get('headline')),
'description': unescapeHTML(json_ld.get('articleBody')),
})
elif item_type == 'VideoObject':
info.update({
'title': unescapeHTML(json_ld.get('name')),
'description': unescapeHTML(json_ld.get('description')),
'upload_date': unified_strdate(json_ld.get('upload_date')),
'url': unescapeHTML(json_ld.get('contentUrl')),
})
return dict((k, v) for k, v in info.items() if v is not None)
@staticmethod