feat: 비밀번호 재설정을 password-reset-requests/password-resets API에 연결 - #278
Merged
Conversation
ForgotPasswordPage·ResetPasswordPage가 서버 호출 없이 다음 화면으로 그냥 navigate만 하던 정적 mock 상태였음. server #100의 재설정 API에 실제로 연결. - ForgotPasswordPage: 제출 시 POST /auth/password-reset-requests 호출, 성공하면 기존처럼 /email-sent로 이동 - ResetPasswordPage: URL의 token 쿼리 파라미터를 읽어 POST /auth/password-resets 호출, 토큰 없음/서버 400 시 기존에 있던 "링크가 만료되었나요?" 안내를 실제로 트리거 - apiFetch 버그 수정: 204만 특별 취급하고 있어서, password-reset-requests처럼 body 없이 202를 반환하는 응답에서 response.json()이 빈 문자열 파싱에 실패하던 문제. status 코드 대신 실제 body가 비어있는지로 판단하도록 변경 (client.test.ts에 회귀 테스트 추가) - 로컬 서버에 실제로 붙여서 요청 성공/토큰 없음/토큰 무효 세 경로 모두 브라우저로 확인함 Closes #277
This was referenced Aug 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
요약
POST /auth/password-reset-requests,POST /auth/password-resets에ForgotPasswordPage/ResetPasswordPage를 연결 — 지금까지는 서버 호출 없이 다음 화면으로 그냥 navigate만 하던 정적 mock이었음ResetPasswordPage는 URL의token쿼리 파라미터를 읽어서 사용, 토큰 없음/서버 400(무효·만료) 시 기존에 이미 있던 "링크가 만료되었나요?" 안내가 실제로 트리거되게 함apiFetch가 204만 "본문 없음"으로 특별 취급하고 있어서,password-reset-requests처럼 body 없이 202를 반환하는 응답에서response.json()이 빈 문자열을 파싱하려다 실패하던 문제 발견. status 코드가 아니라 실제 body가 비어있는지로 판단하도록 수정 (다른 202-무본문 엔드포인트에도 재발 방지,client.test.ts에 회귀 테스트 추가)검증
npx tsc -b✅npm run lint✅npx vitest run— 356/356 통과 (신규 5건 포함) ✅npm run build✅/email-sent, 토큰 없이 접근, 서버가 무효 토큰에 400 응답하는 케이스까지 전부 확인함Closes #277