changeset 22:a60cf57d6628

hopefully fix unicode issue
author Jeff Hammel <jhammel@mozilla.com>
date Mon, 29 Aug 2011 22:54:21 -0700
parents 183224756ded
children 1589a4ed8e44
files uploader/handlers.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/uploader/handlers.py	Mon Aug 01 23:53:33 2011 -0700
+++ b/uploader/handlers.py	Mon Aug 29 22:54:21 2011 -0700
@@ -43,7 +43,7 @@
             contents = os.listdir(self.app.directory)
             if contents:
                 contents.sort()
-                form += '<div><i>Currently uploaded:<ul><li>' + '</li><li>'.join(contents) + '</li></ul></i></div>'
+                form += '<div><i>Currently uploaded:<ul><li>' + '</li><li>'.join([i.decode('utf-8', 'ignore') for i in contents]) + '</li></ul></i></div>'
             else:
                 form += '<div><i>No files in upload directory</i></div>'
             log_file = self.app.log_file