From ee64d06e0a63074c102656c0aefd873082d738a0 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Thu, 19 Sep 2024 00:52:24 +0200 Subject: [PATCH] fix audio track issue --- src/main.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 814ed76..d896c29 100644 --- a/src/main.ts +++ b/src/main.ts @@ -89,7 +89,7 @@ app.whenReady().then(() => { const tmpFile = getNewFilename(file, "TMP_"); let outFile; - const audioTracks = getNumberOfAudioTracks(file); + let audioTracks = getNumberOfAudioTracks(file); switch (audioTracks.length) { case 2: @@ -120,6 +120,8 @@ app.whenReady().then(() => { // Delete the temporary video file deleteFile(tmpFile); + audioTracks = getNumberOfAudioTracks(outFile); + break; default: // Other cases: no merge needed