make sure path exists
This commit is contained in:
parent
a9ae0ab5e6
commit
d48254c1d2
1 changed files with 1 additions and 0 deletions
|
@ -244,6 +244,7 @@ class File(models.Model):
|
|||
format=config['formats'][0])
|
||||
if created:
|
||||
stream.video.name = stream.name()
|
||||
ox.makedirs(os.path.dirname(stream.video.path))
|
||||
with open(stream.video.path, 'w') as f:
|
||||
f.write(chunk.read())
|
||||
else:
|
||||
|
|
Loading…
Reference in a new issue