修复DALL-E兼容图像接口

This commit is contained in:
Vinlic 2024-06-12 11:31:45 +08:00
parent 34282ad837
commit 72b3698757

View File

@ -1064,10 +1064,10 @@ async function receiveImages(
throw new APIException(EX.API_CONTENT_FILTERED);
if (result.status != "finish") {
result.parts.forEach((part) => {
const { content } = part;
const { status: partStatus, content } = part;
if (!_.isArray(content)) return;
content.forEach((value) => {
const { status: partStatus, type, image, text } = value;
const { type, image, text } = value;
if (
type == "image" &&
_.isArray(image) &&