Ver Fonte

fix: Properly structure Google Drive file upload data for dispatch

Taylor Wilsdon (aider) há 4 meses atrás
pai
commit
eef18d4440
1 ficheiros alterados com 8 adições e 1 exclusões
  1. 8 1
      src/lib/components/chat/MessageInput.svelte

+ 8 - 1
src/lib/components/chat/MessageInput.svelte

@@ -501,7 +501,14 @@
 											try {
 												const fileData = await createPicker();
 												if (fileData) {
-													dispatch('upload', { type: 'google-drive', data: fileData });
+													dispatch('upload', { 
+														type: 'google-drive', 
+														data: {
+															name: fileData.name,
+															url: fileData.url,
+															id: fileData.id
+														}
+													});
 												}
 											} catch (error) {
 												console.error('Google Drive Error:', error);