Fix pre-formatted delete
This commit is contained in:
parent
eef0b94c25
commit
2437b98e92
@ -59,7 +59,7 @@ app.post("/uploadVideo", async (req, res) => {
|
|||||||
const fileStream = fs.createWriteStream(targetPath);
|
const fileStream = fs.createWriteStream(targetPath);
|
||||||
uploadingFile.pipe(fileStream);
|
uploadingFile.pipe(fileStream);
|
||||||
fileStream.on("close", () => {
|
fileStream.on("close", () => {
|
||||||
console.log(`Completed upload ${fileInfo.filename}`);
|
console.log(`Completed upload ${videoId}`);
|
||||||
const ffmpegCommand = `ffmpeg -y -loglevel error -i "${targetPath}" -c:v libx264 -crf 23 -preset medium -movflags +faststart -c:a aac -b:a 128k ${formattedPath}`;
|
const ffmpegCommand = `ffmpeg -y -loglevel error -i "${targetPath}" -c:v libx264 -crf 23 -preset medium -movflags +faststart -c:a aac -b:a 128k ${formattedPath}`;
|
||||||
currentlyExecFfmpeg = true;
|
currentlyExecFfmpeg = true;
|
||||||
|
|
||||||
@ -74,6 +74,7 @@ app.post("/uploadVideo", async (req, res) => {
|
|||||||
videoId,
|
videoId,
|
||||||
formattedPath
|
formattedPath
|
||||||
);
|
);
|
||||||
|
fs.unlinkSync(targetPath);
|
||||||
fs.unlinkSync(formattedPath);
|
fs.unlinkSync(formattedPath);
|
||||||
console.log(
|
console.log(
|
||||||
await minioClient.presignedGetObject(
|
await minioClient.presignedGetObject(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user