From c82a734d1fbf6b51d28424307e07d6513c2acedc Mon Sep 17 00:00:00 2001 From: Lee Youl <2yulrang@gmail.com> Date: Sun, 24 Nov 2024 20:26:03 +0900 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix:=20=ED=81=AC=EB=A3=A8?= =?UTF-8?q?=EB=A7=8C=EB=93=A4=EA=B8=B0=20Exception=20Error=20fix?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../common/input/file-input-wrap/file-input/index.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/common/input/file-input-wrap/file-input/index.tsx b/src/components/common/input/file-input-wrap/file-input/index.tsx index 29fe705d..dff47b54 100644 --- a/src/components/common/input/file-input-wrap/file-input/index.tsx +++ b/src/components/common/input/file-input-wrap/file-input/index.tsx @@ -26,6 +26,10 @@ export default function FileInput({ value, isBlur, error, onChange }: FileInputP const fileInput = useRef(null); const handleFileLoad = (file: File) => { + if (!file || !(file instanceof Blob)) { + return; + } + // 이전 FileReader가 있을 경우 중단 if (fileReader) { fileReader.abort();