Try to fix video duplication
This commit is contained in:
parent
dea16773df
commit
217ffacfdd
|
@ -185,7 +185,7 @@ export class VideosRedundancyScheduler extends AbstractScheduler {
|
||||||
const tmpPath = await downloadWebTorrentVideo({ magnetUri }, VIDEO_IMPORT_TIMEOUT)
|
const tmpPath = await downloadWebTorrentVideo({ magnetUri }, VIDEO_IMPORT_TIMEOUT)
|
||||||
|
|
||||||
const destPath = join(CONFIG.STORAGE.REDUNDANCY_DIR, video.getVideoFilename(file))
|
const destPath = join(CONFIG.STORAGE.REDUNDANCY_DIR, video.getVideoFilename(file))
|
||||||
await move(tmpPath, destPath)
|
await move(tmpPath, destPath, { overwrite: true })
|
||||||
|
|
||||||
const createdModel = await VideoRedundancyModel.create({
|
const createdModel = await VideoRedundancyModel.create({
|
||||||
expiresOn: this.buildNewExpiration(redundancy.minLifetime),
|
expiresOn: this.buildNewExpiration(redundancy.minLifetime),
|
||||||
|
|
Loading…
Reference in New Issue