windows require to remove old_file before doing os.rename(new_file, old_file)
This commit is contained in:
parent
759ddff650
commit
d84b63b172
|
@ -878,6 +878,9 @@ class GroupchatControl(ChatControlBase):
|
|||
os.path.join(path, puny_new_nick + ext)
|
||||
for old_file in files:
|
||||
if os.path.exists(old_file):
|
||||
if os.path.exists(files[old_file]):
|
||||
# Windows require this
|
||||
os.remove(files[old_file])
|
||||
os.rename(old_file, files[old_file])
|
||||
self.print_conversation(s, 'info')
|
||||
|
||||
|
|
Loading…
Reference in New Issue