diff --git a/app/components/chat.tsx b/app/components/chat.tsx index d730a4a102c..bcd0e605df2 100644 --- a/app/components/chat.tsx +++ b/app/components/chat.tsx @@ -1102,9 +1102,9 @@ function _Chat() { }, []); const handlePaste = useCallback( - const currentModel = chatStore.currentSession().mask.modelConfig.model; - if(!isVisionModel(currentModel)){return;} async (event: React.ClipboardEvent) => { + const currentModel = chatStore.currentSession().mask.modelConfig.model; + if(!isVisionModel(currentModel)){return;} const items = (event.clipboardData || window.clipboardData).items; for (const item of items) { if (item.kind === "file" && item.type.startsWith("image/")) {