Fix file attachment API format and duplicate attachments
- Add required 'url' field to file parts in API request - Use url, mime, filename instead of path field - Prevent duplicate attachments by checking if path already exists - Show all files when picker opens with empty query (use space as query) - Filter git files only when search query provided - Enter key now works correctly when file list has items
This commit is contained in:
@@ -652,8 +652,9 @@ async function sendMessage(
|
||||
if (source.type === "file") {
|
||||
parts.push({
|
||||
type: "file" as const,
|
||||
path: source.path,
|
||||
url: att.url,
|
||||
mime: source.mime,
|
||||
filename: att.filename,
|
||||
})
|
||||
} else if (source.type === "text") {
|
||||
parts.push({
|
||||
|
||||
Reference in New Issue
Block a user