提交 ee3898e1 编写于 作者: R repsac

Fixed a bug that was occuring when removing destination files.

上级 348a3c3c
......@@ -14,10 +14,12 @@ def copy_registered_textures(dest, registration):
def copy(src, dst):
logger.debug('io.copy(%s, %s)' % (src, dst))
if os.path.exists(dst) and os.path.isfile(src):
if os.path.isfile(src):
file_name = os.path.basename(src)
dst = os.path.join(dst, file_name)
if os.path.exists(dst):
logger.info('Destination file exists, attempting to remove %s', dst)
try:
os.remove(dst)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册