From 0d7c59f1f035d51a7409449bc4e335928a6b29bd Mon Sep 17 00:00:00 2001 From: Clinton Hall Date: Wed, 13 Nov 2019 18:32:03 +1300 Subject: [PATCH] Remove Encode of directory #1671 (#1672) --- core/utils/files.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/core/utils/files.py b/core/utils/files.py index 726d4209..f29efa6b 100644 --- a/core/utils/files.py +++ b/core/utils/files.py @@ -53,10 +53,11 @@ def move_file(mediafile, path, link): title = os.path.splitext(os.path.basename(mediafile))[0] new_path = os.path.join(path, sanitize_name(title)) - try: - new_path = new_path.encode(core.SYS_ENCODING) - except Exception: - pass + # Removed as encoding of directory no-longer required + #try: + # new_path = new_path.encode(core.SYS_ENCODING) + #except Exception: + # pass # Just fail-safe incase we already have afile with this clean-name (was actually a bug from earlier code, but let's be safe). if os.path.isfile(new_path):