mirror of
https://github.com/ankitects/anki.git
synced 2025-09-19 22:42:25 -04:00
rename rather than copy file if same name but different case in media check
This commit is contained in:
parent
5692c91855
commit
4d1ea887dd
1 changed files with 1 additions and 1 deletions
|
@ -66,7 +66,7 @@ Update media table. If file already exists, don't copy."""
|
|||
if not os.path.exists(new):
|
||||
if new.lower() == path.lower():
|
||||
# case insensitive filesystems suck
|
||||
pass
|
||||
os.rename(path, new)
|
||||
else:
|
||||
shutil.copy2(path, new)
|
||||
newSize = os.stat(new)[stat.ST_SIZE]
|
||||
|
|
Loading…
Reference in a new issue