Commits

Jason R. Coombs committed 33efe06

Fixed unicode issues in guess_output_filename

  • Participants
  • Parent commits a3c4c74
  • Tags 1.8.1

Comments (0)

Files changed (1)

jaraco/media/dvd.py

+from __future__ import unicode_literals
+
 import optparse
 import re
 import os
 def guess_output_filename(name):
 	"""
 	>>> guess_output_filename('JEAN_DE_FLORETTE')
-	'Jean De Florette'
+	u'Jean De Florette'
 
 	>>> guess_output_filename('')
-	''
+	u''
 
 	>>> guess_output_filename('COWBOYS_ALIENS_RENTAL')
-	'Cowboys Aliens'
+	u'Cowboys Aliens'
 	"""
 	names = name.split('_')
-	names = map(str.capitalize, names)
+	names = map(unicode.capitalize, names)
 	if names and names[-1] == 'Rental':
 		names = names[:-1]
 	return ' '.join(names)