From 5c34afc228d16d6d499a5cab243f966ef380c360 Mon Sep 17 00:00:00 2001 From: linyuchen Date: Thu, 21 Mar 2024 13:34:49 +0800 Subject: [PATCH] fix: audio duration --- src/common/utils/file.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/utils/file.ts b/src/common/utils/file.ts index 05556d9..0da7968 100644 --- a/src/common/utils/file.ts +++ b/src/common/utils/file.ts @@ -155,7 +155,7 @@ export async function encodeSilk(filePath: string) { fs.writeFileSync(pttPath, silk.data); fs.unlink(wavPath, (err) => { }); - const gDuration = await guessDuration(filePath) + const gDuration = await guessDuration(pttPath) log(`语音文件${filePath}转换成功!`, pttPath, `时长:`, silk.duration) return { converted: true,