Skip to content

Formerly KrillinAI, VideoTranslation and Dubbing Tool for 120+ Languages. Open-source AI workspace for creators, powered by Codex. Video downloader, video translation, create videos, images, audios, and edits with Agents in one place. For your Social Media like YouTube, TikTok, Instagram, etc.

fix: tts error when bilingual subtitle set to false

沈浩2a82a332c8e2
diff --git a/internal/service/audio2subtitle.go b/internal/service/audio2subtitle.go
index 6142c4f4..c5d43130 100644
--- a/internal/service/audio2subtitle.go
+++ b/internal/service/audio2subtitle.go
@@ -496,10 +496,11 @@ func splitSrt(stepParam *types.SubtitleTaskStepParam) error {
subtitleInfo.Name = "双语字幕"
}
stepParam.SubtitleInfos = append(stepParam.SubtitleInfos, subtitleInfo)
- // 供生成配音使用
- stepParam.TtsSourceFilePath = stepParam.BilingualSrtFilePath
}
+ // 供生成配音使用
+ stepParam.TtsSourceFilePath = stepParam.BilingualSrtFilePath
+
log.GetLogger().Info("audioToSubtitle.splitSrt end", zap.Any("task id", stepParam.TaskId))
return nil
}