Correction des chemins d'accès aux répertoires dans la route GET /projects/:id/create-video
This commit is contained in:
@@ -50,10 +50,10 @@ router.get('/projects', async (req, res) => {
|
|||||||
*/
|
*/
|
||||||
router.get('/projects/:id/create-video', async (req, res) => {
|
router.get('/projects/:id/create-video', async (req, res) => {
|
||||||
const projectId = req.params.id;
|
const projectId = req.params.id;
|
||||||
const imageDir = path.join(__dirname, `../storage/${projectId}`);
|
const imageDir = path.join(__dirname, `/storage/${projectId}`);
|
||||||
const outputVideo = path.join(__dirname, `../storage/${projectId}/output_video.mp4`);
|
const outputVideo = path.join(__dirname, `/storage/${projectId}/output_video.mp4`);
|
||||||
const frameRate = 24;
|
const frameRate = 24;
|
||||||
const tempFile = path.join(__dirname, `../storage/${projectId}/temp_file.txt`);
|
const tempFile = path.join(__dirname, `/storage/${projectId}/temp_file.txt`);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const images = fs.readdirSync(imageDir).filter(file => file.endsWith('.jpg'));
|
const images = fs.readdirSync(imageDir).filter(file => file.endsWith('.jpg'));
|
||||||
|
|||||||
Reference in New Issue
Block a user