ソースを参照

[compat] Correct compat_basestring definition

Philipp Hagemeister 10 年 前
コミット
0196149c5b
1 ファイル変更3 行追加2 行削除
  1. 3 2
      youtube_dl/compat.py

+ 3 - 2
youtube_dl/compat.py

@@ -120,9 +120,9 @@ except NameError:
     compat_str = str
     compat_str = str
 
 
 try:
 try:
-    compat_basestr = basestring  # Python 2
+    compat_basestring = basestring  # Python 2
 except NameError:
 except NameError:
-    compat_basestr = str
+    compat_basestring = str
 
 
 try:
 try:
     compat_chr = unichr  # Python 2
     compat_chr = unichr  # Python 2
@@ -367,6 +367,7 @@ def workaround_optparse_bug9161():
 
 
 __all__ = [
 __all__ = [
     'compat_HTTPError',
     'compat_HTTPError',
+    'compat_basestring',
     'compat_chr',
     'compat_chr',
     'compat_cookiejar',
     'compat_cookiejar',
     'compat_expanduser',
     'compat_expanduser',