mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-13 04:48:53 +00:00
fix: copilot blob process (#6612)
This commit is contained in:
@@ -113,8 +113,9 @@ export class OpenAIProvider
|
||||
!m ||
|
||||
// check content
|
||||
typeof m.content !== 'string' ||
|
||||
!m.content ||
|
||||
!m.content.trim()
|
||||
// content and attachments must exist at least one
|
||||
((!m.content || !m.content.trim()) &&
|
||||
(!Array.isArray(m.attachments) || !m.attachments.length))
|
||||
)
|
||||
) {
|
||||
throw new Error('Empty message content');
|
||||
|
||||
Reference in New Issue
Block a user