From dc02fb4a06b99a220f6fd2196487e4ddb2c70dab Mon Sep 17 00:00:00 2001 From: Ade Date: Fri, 18 Jul 2014 20:45:56 +1200 Subject: [PATCH] Rename file fails if starts with '.' Fixes https://github.com/rembo10/headphones/issues/1317 --- headphones/postprocessor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/headphones/postprocessor.py b/headphones/postprocessor.py index 15e5eb29..27b3a25b 100644 --- a/headphones/postprocessor.py +++ b/headphones/postprocessor.py @@ -945,7 +945,7 @@ def renameFiles(albumpath, downloaded_track_list, release): new_file_name = new_file_name.replace(' ', '_') if new_file_name.startswith('.'): - new_file_name = new_file_name.replace(0, '_') + new_file_name = new_file_name.replace(".", "_", 1) new_file = os.path.join(albumpath, new_file_name)