This commit is contained in:
Timothy Jaeryang Baek 2025-12-21 23:22:14 +04:00
parent f1bf4f20c5
commit bd7f1869ce

View file

@ -1604,7 +1604,7 @@
..._files.filter(
(item) =>
['doc', 'text', 'note', 'chat', 'folder', 'collection'].includes(item.type) ||
(item.type === 'file' && !item?.content_type?.startsWith('image/'))
(item.type === 'file' && !(item?.content_type ?? '').startsWith('image/'))
)
);
chatFiles = chatFiles.filter(
@ -1831,7 +1831,7 @@
...(userMessage?.files ?? []).filter(
(item) =>
['doc', 'text', 'note', 'chat', 'collection'].includes(item.type) ||
(item.type === 'file' && !item?.content_type.startsWith('image/'))
(item.type === 'file' && !(item?.content_type ?? '').startsWith('image/'))
)
);
// Remove duplicates