summary refs log tree commit diff
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2017-06-09 00:20:07 +0700
committerSergey M․ <dstftw@gmail.com>2017-06-09 00:20:07 +0700
commit15aeeb11882c9597614ce6e249968bfdf7830e8a (patch)
tree52701cc8ce97fe509d992feedd00ad56a96cb271
parent1693bebe4d3e605001b1df8b6e1f238c2e3ff897 (diff)
downloadyoutube-dl-15aeeb11882c9597614ce6e249968bfdf7830e8a.tar.gz
youtube-dl-15aeeb11882c9597614ce6e249968bfdf7830e8a.tar.xz
youtube-dl-15aeeb11882c9597614ce6e249968bfdf7830e8a.zip
[flickr] Ensure format id is string
-rw-r--r--youtube_dl/extractor/flickr.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/youtube_dl/extractor/flickr.py b/youtube_dl/extractor/flickr.py
index a8e1bf42a..9f166efd4 100644
--- a/youtube_dl/extractor/flickr.py
+++ b/youtube_dl/extractor/flickr.py
@@ -1,7 +1,10 @@
 from __future__ import unicode_literals
 
 from .common import InfoExtractor
-from ..compat import compat_urllib_parse_urlencode
+from ..compat import (
+    compat_str,
+    compat_urllib_parse_urlencode,
+)
 from ..utils import (
     ExtractorError,
     int_or_none,
@@ -81,7 +84,7 @@ class FlickrIE(InfoExtractor):
 
             formats = []
             for stream in streams['stream']:
-                stream_type = str(stream.get('type'))
+                stream_type = compat_str(stream.get('type'))
                 formats.append({
                     'format_id': stream_type,
                     'url': stream['_content'],