diff --git a/routes/api.js b/routes/api.js index 7c2813c..492c4f4 100644 --- a/routes/api.js +++ b/routes/api.js @@ -50,10 +50,10 @@ router.get('/projects', async (req, res) => { */ router.get('/projects/:id/create-video', async (req, res) => { const projectId = req.params.id; - const imageDir = path.join(__dirname, `../storage/${projectId}`); - const outputVideo = path.join(__dirname, `../storage/${projectId}/output_video.mp4`); + const imageDir = path.join(__dirname, `/storage/${projectId}`); + const outputVideo = path.join(__dirname, `/storage/${projectId}/output_video.mp4`); const frameRate = 24; - const tempFile = path.join(__dirname, `../storage/${projectId}/temp_file.txt`); + const tempFile = path.join(__dirname, `/storage/${projectId}/temp_file.txt`); try { const images = fs.readdirSync(imageDir).filter(file => file.endsWith('.jpg'));