From 23aa4588586300b3f4f45419c2a147b65489e36c Mon Sep 17 00:00:00 2001 From: seorinn Date: Mon, 11 May 2026 15:37:07 +0900 Subject: [PATCH 1/2] =?UTF-8?q?fix:=20[TA-213]=20deleteSavedPhotographer?= =?UTF-8?q?=EC=97=90=20await=20=EB=88=84=EB=9D=BD=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/PhotographerInfo/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/PhotographerInfo/index.tsx b/src/components/PhotographerInfo/index.tsx index d6445ca..3c6b27d 100644 --- a/src/components/PhotographerInfo/index.tsx +++ b/src/components/PhotographerInfo/index.tsx @@ -40,7 +40,7 @@ export default function PhotographerInfo({ isMypage, userInfo }: Props) { setIsSavedPhotographer(!isSavedPhotographer); try { isSavedPhotographer - ? deleteSavedPhotographer(userInfo.id) + ? await deleteSavedPhotographer(userInfo.id) : await savePhotographer(userInfo.id); } catch (e) { setShowLoginModal(true); From 30f171f5c53b7ac4edbc65ccc9c514ca74da1b1e Mon Sep 17 00:00:00 2001 From: seorinn Date: Mon, 11 May 2026 15:40:56 +0900 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20[TA-213]=20API=20=EC=8B=A4=ED=8C=A8?= =?UTF-8?q?=20=EC=8B=9C=20=EB=82=99=EA=B4=80=EC=A0=81=20UI=20=EC=97=85?= =?UTF-8?q?=EB=8D=B0=EC=9D=B4=ED=8A=B8=20=EB=A1=A4=EB=B0=B1=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/PhotographerInfo/index.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/components/PhotographerInfo/index.tsx b/src/components/PhotographerInfo/index.tsx index 3c6b27d..ef37c8b 100644 --- a/src/components/PhotographerInfo/index.tsx +++ b/src/components/PhotographerInfo/index.tsx @@ -36,6 +36,8 @@ export default function PhotographerInfo({ isMypage, userInfo }: Props) { }; const toggleSavePhotographer = async () => { + const prevCount = count; + const prevIsSaved = isSavedPhotographer; setCount(isSavedPhotographer ? count - 1 : count + 1); setIsSavedPhotographer(!isSavedPhotographer); try { @@ -43,6 +45,8 @@ export default function PhotographerInfo({ isMypage, userInfo }: Props) { ? await deleteSavedPhotographer(userInfo.id) : await savePhotographer(userInfo.id); } catch (e) { + setCount(prevCount); + setIsSavedPhotographer(prevIsSaved); setShowLoginModal(true); console.log(e); }