From e1a47a6a116a335b04fd49c937914558ec7540d9 Mon Sep 17 00:00:00 2001 From: yoosangwook Date: Fri, 10 Jan 2025 19:00:30 +0900 Subject: [PATCH] test: image file upload prod mode error --- src/hooks/common/useRefFiles.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/hooks/common/useRefFiles.js b/src/hooks/common/useRefFiles.js index df0b5634..bb079bc7 100644 --- a/src/hooks/common/useRefFiles.js +++ b/src/hooks/common/useRefFiles.js @@ -149,7 +149,8 @@ export function useRefFiles() { formData.append('file', file) formData.append('fileName', currentCanvasPlan.id) - const res = await post({ url: 'http://localhost:3000/api/image-upload', data: formData }) + // const res = await post({ url: `${process.env.NEXT_PUBLIC_API_SERVER_PATH}/api/image-upload`, data: formData }) + const res = await post({ url: `http://localhost:3000/api/image-upload`, data: formData }) console.log('🚀 ~ handleUploadImageRefFile ~ res:', res) const image = await readImage(res.fileNm) console.log('🚀 ~ handleUploadImageRefFile ~ file:', image)