[heise] Don't check string type
authorMats <d912e3@gmail.com>
Sat, 27 Sep 2014 19:12:23 +0000 (21:12 +0200)
committerMats <d912e3@gmail.com>
Sat, 27 Sep 2014 19:12:23 +0000 (21:12 +0200)
Before Python 3 could be unicode, so don't check at all.

youtube_dl/extractor/heise.py

index b3cb10fde4f900402add8033165c4b35988f5225..73c9531813592fe32318f2586586cf98fd37b7a8 100644 (file)
@@ -88,8 +88,7 @@ class HeiseIE(InfoExtractor):
             for res, obj in rs.items():
                 format_id = '{0}_{1}'.format(t, res)
 
-                if (not obj or not obj.get('url') or
-                        not isinstance(obj['url'], str)):
+                if not obj or not obj.get('url'):
                     self._warn('formats: {0}: no url', format_id)
                     continue
 
@@ -107,11 +106,11 @@ class HeiseIE(InfoExtractor):
         self._sort_formats(formats)
         info['formats'] = formats
 
-        if config.get('poster') and isinstance(config['poster'], str):
+        if config.get('poster'):
             info['thumbnail'] = config['poster']
 
         date = get_meta_content('date', html)
-        if date and isinstance(date, str):
+        if date:
             try:
                 info['timestamp'] = parse_iso8601(date)
             except ValueError as e: