Browse Source

Use re.DOTALL by default when searching OpenGraph properties

rtmp_test
Jaime Marquínez Ferrándiz 12 years ago
parent
commit
44dbe89035
2 changed files with 2 additions and 2 deletions
  1. +1
    -1
      youtube_dl/extractor/common.py
  2. +1
    -1
      youtube_dl/extractor/funnyordie.py

+ 1
- 1
youtube_dl/extractor/common.py View File

@ -265,7 +265,7 @@ class InfoExtractor(object):
def _og_search_property(self, property, html, name=None, **kargs):
if name is None:
name = 'OpenGraph %s' % property
return self._html_search_regex(self._og_regex(property), html, name, **kargs)
return self._html_search_regex(self._og_regex(property), html, name, flags=re.DOTALL, **kargs)
def _og_search_thumbnail(self, html, **kargs):
return self._og_search_property('image', html, 'thumbnail url', fatal=False, **kargs)


+ 1
- 1
youtube_dl/extractor/funnyordie.py View File

@ -32,6 +32,6 @@ class FunnyOrDieIE(InfoExtractor):
'url': video_url,
'ext': 'mp4',
'title': title,
'description': self._og_search_description(webpage, flags=re.DOTALL),
'description': self._og_search_description(webpage),
}
return [info]

Loading…
Cancel
Save