|
@@ -14,10 +14,12 @@ def copy_registered_textures(dest, registration):
|
|
|
|
|
|
def copy(src, dst):
|
|
def copy(src, dst):
|
|
logger.debug('io.copy(%s, %s)' % (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)
|
|
file_name = os.path.basename(src)
|
|
dst = os.path.join(dst, file_name)
|
|
dst = os.path.join(dst, file_name)
|
|
|
|
|
|
|
|
+ if os.path.exists(dst):
|
|
|
|
+
|
|
logger.info('Destination file exists, attempting to remove %s', dst)
|
|
logger.info('Destination file exists, attempting to remove %s', dst)
|
|
try:
|
|
try:
|
|
os.remove(dst)
|
|
os.remove(dst)
|