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 clone by audio file

scwf3eafd41685e9
diff --git a/internal/handler/subtitle_task.go b/internal/handler/subtitle_task.go
index 070a39dc..82b5c41e 100644
--- a/internal/handler/subtitle_task.go
+++ b/internal/handler/subtitle_task.go
@@ -4,6 +4,7 @@ import (
"github.com/gin-gonic/gin"
"krillin-ai/internal/dto"
"krillin-ai/internal/response"
+ "log"
"os"
"path/filepath"
)
@@ -11,6 +12,7 @@ import (
func (h Handler) StartSubtitleTask(c *gin.Context) {
var req dto.StartVideoSubtitleTaskReq
if err := c.ShouldBindJSON(&req); err != nil {
+ log.Printf("参数绑定错误: %v", err) // 打印详细的绑定错误信息
response.R(c, response.Response{
Error: -1,
Msg: "参数错误",
diff --git a/static/index.html b/static/index.html
index 38b12848..83421909 100644
--- a/static/index.html
+++ b/static/index.html
@@ -621,7 +621,7 @@
if (formData.tts === 1) {
formData.tts_voice_code = +voiceoverVoice.value;
if (uploadedAudioUrl) {
- formData.tts_voice_clone_src_file_url = uploadedAudioUrl;
+ formData.tts_voice_clone_src_file_url = uploadedAudioUrl[0];
}
}