From 4c4d8dd05d6e9e6151d638a5e40be018c036e792 Mon Sep 17 00:00:00 2001 From: wxg0103 <727495428@qq.com> Date: Fri, 5 Dec 2025 14:31:35 +0800 Subject: [PATCH] fix: enhance file upload limit check to account for multiple conditions --- .../components/ai-chat/component/chat-input-operate/index.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/src/components/ai-chat/component/chat-input-operate/index.vue b/ui/src/components/ai-chat/component/chat-input-operate/index.vue index 42990c053..7fb67ec9d 100644 --- a/ui/src/components/ai-chat/component/chat-input-operate/index.vue +++ b/ui/src/components/ai-chat/component/chat-input-operate/index.vue @@ -1202,7 +1202,7 @@ async function saveUrl() { uploadAudioList.value.length + uploadVideoList.value.length + uploadOtherList.value.length - if (file_limit_once + urls.length >= maxFiles) { + if (file_limit_once >= maxFiles || urls.length + file_limit_once >= fileLimit || urls.length > fileLimit) { MsgWarning(t('chat.uploadFile.limitMessage1') + maxFiles + t('chat.uploadFile.limitMessage2')) return }