1
1
mirror of https://github.com/ytdl-org/youtube-dl synced 2024-12-24 04:25:51 +01:00

[motherless] Make categories optional (Closes #8654)

This commit is contained in:
Sergey M․ 2016-02-25 00:36:14 +06:00
parent c0da50d2b2
commit 43479d9e9d

View File

@ -54,6 +54,11 @@ class MotherlessIE(InfoExtractor):
'thumbnail': 're:http://.*\.jpg',
'age_limit': 18,
}
},
{
# no keywords
'url': 'http://motherless.com/8B4BBC1',
'only_matching': True,
}
]
@ -86,7 +91,7 @@ class MotherlessIE(InfoExtractor):
r'"thumb-member-username">\s+<a href="/m/([^"]+)"',
webpage, 'uploader_id')
categories = self._html_search_meta('keywords', webpage)
categories = self._html_search_meta('keywords', webpage, default=None)
if categories:
categories = [cat.strip() for cat in categories.split(',')]