aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/FileDownloader.py
diff options
context:
space:
mode:
authorPhilipp Hagemeister <phihag@phihag.de>2012-11-27 19:02:37 +0100
committerPhilipp Hagemeister <phihag@phihag.de>2012-11-27 19:02:37 +0100
commitdd109dee8ebd51a019529fa494e56651162ad6d9 (patch)
treeaee4e19aac29736b5895ba0a17547b1d9617d927 /youtube_dl/FileDownloader.py
parentb514df2034a7291971427588977dd612c4b5581f (diff)
downloadyoutube-dl-dd109dee8ebd51a019529fa494e56651162ad6d9.tar.xz
Remove mentions of unicode
Diffstat (limited to 'youtube_dl/FileDownloader.py')
-rw-r--r--youtube_dl/FileDownloader.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/youtube_dl/FileDownloader.py b/youtube_dl/FileDownloader.py
index d7d5b1521..777a52545 100644
--- a/youtube_dl/FileDownloader.py
+++ b/youtube_dl/FileDownloader.py
@@ -330,7 +330,7 @@ class FileDownloader(object):
template_dict['epoch'] = int(time.time())
template_dict['autonumber'] = u'%05d' % self._num_downloads
- template_dict = dict((k, sanitize_filename(compat_str(v), self.params.get('restrictfilenames'))) for k,v in template_dict.items())
+ template_dict = dict((k, sanitize_filename(u(v), self.params.get('restrictfilenames'))) for k,v in template_dict.items())
filename = self.params['outtmpl'] % template_dict
return filename
except (ValueError, KeyError), err:
@@ -397,7 +397,7 @@ class FileDownloader(object):
if dn != '' and not os.path.exists(dn): # dn is already encoded
os.makedirs(dn)
except (OSError, IOError), err:
- self.trouble(u'ERROR: unable to create directory ' + unicode(err))
+ self.trouble(u'ERROR: unable to create directory ' + u(err))
return
if self.params.get('writedescription', False):