1
0
Fork 0
mirror of https://github.com/blackjack4494/yt-dlc.git synced 2024-12-23 00:07:49 +00:00

[livestream] Fix FutureWarning (Closes #8742)

This commit is contained in:
Sergey M․ 2016-03-04 01:16:58 +06:00
parent 1255733945
commit e1dd521e49

View file

@ -64,7 +64,7 @@ class LivestreamIE(InfoExtractor):
def _parse_smil_formats(self, smil, smil_url, video_id, namespace=None, f4m_params=None, transform_rtmp_url=None): def _parse_smil_formats(self, smil, smil_url, video_id, namespace=None, f4m_params=None, transform_rtmp_url=None):
base_ele = find_xpath_attr( base_ele = find_xpath_attr(
smil, self._xpath_ns('.//meta', namespace), 'name', 'httpBase') smil, self._xpath_ns('.//meta', namespace), 'name', 'httpBase')
base = base_ele.get('content') if base_ele else 'http://livestreamvod-f.akamaihd.net/' base = base_ele.get('content') if base_ele is not None else 'http://livestreamvod-f.akamaihd.net/'
formats = [] formats = []
video_nodes = smil.findall(self._xpath_ns('.//video', namespace)) video_nodes = smil.findall(self._xpath_ns('.//video', namespace))