Skip to content

Commit

Permalink
hotfix: 디버깅 콘솔 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
pepperdad committed Dec 18, 2024
1 parent 785eeff commit 40a9ca9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/apis/domains/users/queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const usePostKakaoLogin = () => {
mutationFn: (authCode: string) => postKakaoLogin(authCode),
onSuccess: (response) => {
if (response) {
// console.log("login success", response);
console.log("login success", response);

const userData = response;

Expand Down
5 changes: 3 additions & 2 deletions src/hooks/useTokenRefresher.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default function TokenRefresher() {
localStorage.clear();
openAlert({ title: "다시 로그인 해주세요." });
window.location.reload();
return null;
return <></>;
}
}

Expand Down Expand Up @@ -48,6 +48,7 @@ export default function TokenRefresher() {
} catch (refreshError) {
console.error("Token refresh failed:", refreshError);
localStorage.clear();
navigate("/main");
openAlert({ title: "장시간 미활동으로 인해 \n자동으로 로그아웃 되었습니다." });
window.location.reload();
}
Expand All @@ -67,5 +68,5 @@ export default function TokenRefresher() {
};
}, []);

return null;
return <></>;
}

0 comments on commit 40a9ca9

Please sign in to comment.