Browse Source

[brightcove] Always return lists from _extract_brightcove_urls

In Python 3, filter() returns an iterable object, which is equivalently
to True even for an empty result set. It causes false positive playlists
in generic extraction logic.
totalwebcasting
Yen Chi Hsuan 10 years ago
parent
commit
9fc03aa87c
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      youtube_dl/extractor/brightcove.py

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

@ -188,7 +188,7 @@ class BrightcoveIE(InfoExtractor):
[^>]*?>\s*<param\s+name="movie"\s+value="https?://[^/]*brightcove\.com/
).+?>\s*</object>''',
webpage)
return filter(None, [cls._build_brighcove_url(m) for m in matches])
return list(filter(None, [cls._build_brighcove_url(m) for m in matches]))
def _real_extract(self, url):
url, smuggled_data = unsmuggle_url(url, {})


Loading…
Cancel
Save