1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-03-14 13:37:45 +08:00

Use isinstance() instead of type() for a typecheck.

This commit is contained in:
stepshal 2016-06-14 00:06:08 +07:00
parent 79cd8b3d8a
commit 39af63024d

View File

@ -1953,7 +1953,7 @@ class YoutubeDL(object):
if not self.params.get('verbose'):
return
if type('') is not compat_str:
if isinstance('') is not compat_str:
# Python 2.6 on SLES11 SP1 (https://github.com/rg3/youtube-dl/issues/3326)
self.report_warning(
'Your Python is broken! Update to a newer and supported version')