From 45fc29beb87687285b1f4bd81c0f1bef44b1941a Mon Sep 17 00:00:00 2001 From: btimby Date: Fri, 20 Apr 2012 20:08:41 +0000 Subject: Forgot to decode paths in rename() method --- fs/expose/ftp.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'fs/expose') diff --git a/fs/expose/ftp.py b/fs/expose/ftp.py index 0a09581..9b50203 100644 --- a/fs/expose/ftp.py +++ b/fs/expose/ftp.py @@ -101,6 +101,10 @@ class FTPFS(ftpserver.AbstractedFS): @convert_fs_errors def rename(self, src, dst): + if not isinstance(src, unicode): + src = src.decode(self.encoding) + if not isinstance(dst, unicode): + dst = dst.decode(self.encoding) self.fs.rename(src, dst) def chmod(self, path, mode): -- cgit v1.2.1