]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/lib/job-queue/handlers/manage-video-torrent.ts
Reload the video after waiting for the files lock
[github/Chocobozzz/PeerTube.git] / server / lib / job-queue / handlers / manage-video-torrent.ts
index cef93afda011cfd932df166112272a20817b7970..edf52de0cc325c27dd028ae3f972023cc8853496 100644 (file)
@@ -35,6 +35,9 @@ async function doCreateAction (payload: ManageVideoTorrentPayload & { action: 'c
   const fileMutexReleaser = await VideoPathManager.Instance.lockFiles(video.uuid)
 
   try {
+    await video.reload()
+    await file.reload()
+
     await createTorrentAndSetInfoHash(video, file)
 
     // Refresh videoFile because the createTorrentAndSetInfoHash could be long