forked from 0x2620/pandora
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])
|
format=config['formats'][0])
|
||||||
if created:
|
if created:
|
||||||
stream.video.name = stream.name()
|
stream.video.name = stream.name()
|
||||||
|
ox.makedirs(os.path.dirname(stream.video.path))
|
||||||
with open(stream.video.path, 'w') as f:
|
with open(stream.video.path, 'w') as f:
|
||||||
f.write(chunk.read())
|
f.write(chunk.read())
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue