Skip to content

fix: [TA-197] Optimistic Update 에러 시 상태 롤백 처리 추가#102

Merged
seorinn merged 1 commit into
developfrom
TA-197-fix-optimistic-update-rollback
May 13, 2026
Merged

fix: [TA-197] Optimistic Update 에러 시 상태 롤백 처리 추가#102
seorinn merged 1 commit into
developfrom
TA-197-fix-optimistic-update-rollback

Conversation

@seorinn

@seorinn seorinn commented May 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • EventDetail/BottomBar/index.tsxtoggleSavePromotion에서 API 실패 시 UI 상태가 복원되지 않던 버그 수정
  • API 호출 전 prevCount, prevIsSaved를 저장하고, catch에서 롤백
  • PromotionBox, PhotographerBox, PhotographerInfo는 이미 올바르게 구현되어 수정 불필요

Before / After

Before: API 실패 시 저장 카운트와 아이콘 상태가 잘못된 채로 유지
After: API 실패 시 이전 상태로 자동 복원 후 로그인 모달 표시

Test plan

  • 비로그인 상태에서 이벤트 상세 페이지 저장 버튼 클릭 → UI 즉시 변경 → API 실패 → 원래 상태로 복원 및 로그인 모달 표시 확인
  • 로그인 상태에서 저장/취소 정상 동작 확인

@vercel

vercel Bot commented May 13, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
damaba Ready Ready Preview, Comment May 13, 2026 7:23am

@seorinn seorinn marked this pull request as ready for review May 13, 2026 07:25
@seorinn seorinn merged commit 08bdadf into develop May 13, 2026
3 checks passed
@seorinn seorinn deleted the TA-197-fix-optimistic-update-rollback branch May 13, 2026 07:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant