From a9a4f7f659d2f64a3f76b803b6452232642e6718 Mon Sep 17 00:00:00 2001 From: Vinlic Date: Wed, 15 May 2024 10:58:45 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=84=E7=90=86AI=E7=BB=98=E5=9B=BE=E5=AD=97?= =?UTF-8?q?=E6=AE=B5=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/controllers/chat.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/controllers/chat.ts b/src/api/controllers/chat.ts index e983ba0..9f118cb 100644 --- a/src/api/controllers/chat.ts +++ b/src/api/controllers/chat.ts @@ -651,7 +651,7 @@ async function receiveImages( if (role != "assistant" && !_.isString(content)) return str; return str + content; }, ""); - if (result.contentType == "text2image") { + if (result.contentFrom == "text2image") { const urls = text.match( /https?:\/\/[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&//=\,]*)/gi