islink not exists
This commit is contained in:
parent
ecd88fe8a2
commit
215f0db071
1 changed files with 1 additions and 1 deletions
|
@ -59,7 +59,7 @@ class Command(BaseCommand):
|
||||||
src = source.data.path
|
src = source.data.path
|
||||||
target = os.path.join(prefix, 'voice_over', batch, '%s.wav' % fragment_id)
|
target = os.path.join(prefix, 'voice_over', batch, '%s.wav' % fragment_id)
|
||||||
os.makedirs(os.path.dirname(target), exist_ok=True)
|
os.makedirs(os.path.dirname(target), exist_ok=True)
|
||||||
if os.path.exists(target):
|
if os.path.islink(target):
|
||||||
os.unlink(target)
|
os.unlink(target)
|
||||||
os.symlink(src, target)
|
os.symlink(src, target)
|
||||||
voice_over[fragment_id][batch] = {
|
voice_over[fragment_id][batch] = {
|
||||||
|
|
Loading…
Reference in a new issue