diff options
| author | Philipp Hagemeister <phihag@phihag.de> | 2012-11-26 04:23:20 +0100 | 
|---|---|---|
| committer | Philipp Hagemeister <phihag@phihag.de> | 2012-11-26 04:23:20 +0100 | 
| commit | 92b91c18780938283c505f5662c458e049bf3567 (patch) | |
| tree | 8d91ceb8131b4698583704ca62ff77ae35a61779 /youtube_dl/utils.py | |
| parent | 7ec1a206eaedcb35c16ba54289d3c7f92baa59ce (diff) | |
Use character instead of byte strings
Diffstat (limited to 'youtube_dl/utils.py')
| -rw-r--r-- | youtube_dl/utils.py | 5 | 
1 files changed, 5 insertions, 0 deletions
| diff --git a/youtube_dl/utils.py b/youtube_dl/utils.py index 6f53337d4..658fd2686 100644 --- a/youtube_dl/utils.py +++ b/youtube_dl/utils.py @@ -26,6 +26,11 @@ std_headers = {  	'Accept-Language': 'en-us,en;q=0.5',  } +try: +    compat_str = unicode # Python 2 +except NameError: +    compat_str = str +  def preferredencoding():  	"""Get preferred encoding. | 
