Skip to content

Conversation

@ejinn1
Copy link
Member

@ejinn1 ejinn1 commented May 1, 2025

📄 에러 처리 중복 현상 제거

📝 변경 사항 요약

  • 에러 처리 중복 제거

📌 관련 이슈

🔍 변경 사항 상세 설명

이전에 수정한 방식에서 QueryClient에 공통으로 get 요청에 대한 에러 처리를 해두었고 공통 api 함수에서도 공통으로 에러 처리를 하게 되어서 이를 수정

기존에는 mutation 에러가 발생하면 공통 에러처리, useMutation에서 onError로 에러처리가 2번 중복되었다.

get 요청에 대한 에러 처리는 기존처럼 공통으로 두고 공통 api 에서 처리하지 않고 status, message만 넘겨주어 useMutation을 사용한 hook에서 개별로 처리할 수 있도록 하였다.

✅ 확인 사항

  • 코드가 정상적으로 컴파일되는지 확인했습니다.
  • 관련 테스트를 작성하고 모두 통과했는지 확인했습니다.
  • 코드 스타일 가이드에 맞게 작성했습니다.

@ejinn1 ejinn1 added the 🐞 BugFix Something isn't working label May 1, 2025
@ejinn1 ejinn1 self-assigned this May 1, 2025
@ejinn1 ejinn1 linked an issue May 1, 2025 that may be closed by this pull request
1 task
@github-actions
Copy link

github-actions bot commented May 1, 2025

🎉 구현한 기능 Preview: https://front-jqshvkdxu-beoms-projects-53e61468.vercel.app

@ejinn1 ejinn1 merged commit ca2b7dc into main May 1, 2025
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐞 BugFix Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Fix] 에러 처리 공통화 수정

2 participants