소스 검색

Update handleImportFile shorcut condition

cihat 3 년 전
부모
커밋
22b1aaed47
1개의 변경된 파일1개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 2
      src/containers/ImportModal/index.tsx

+ 1 - 2
src/containers/ImportModal/index.tsx

@@ -105,8 +105,7 @@ export const ImportModal: React.FC<ModalProps> = ({ visible, setVisible }) => {
       setVisible(false);
     }
 
-    if (handleEnterKeyPress) {
-      console.log("test enter");
+    if (handleEnterKeyPress && (jsonFile || url)) {
       handleImportFile();
     }
   }, [handleEspacePress, handleEnterKeyPress]);