소스 검색

Update chat.tsx

Snow Kawashiro 1 년 전
부모
커밋
9775660da7
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      app/components/chat.tsx

+ 2 - 2
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<HTMLTextAreaElement>) => {
+      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/")) {