Skip to content

Commit

Permalink
리프레시 토큰 타이머 수정 (#550)
Browse files Browse the repository at this point in the history
fix: checkLoginToken에 clearTimeout 추가
  • Loading branch information
guridaek authored Sep 19, 2023
1 parent 521897b commit 469bcd3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion frontend/src/hooks/useLogin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@ export const useLogin = () => {
const checkLoginToken = async () => {
const token = getAccessToken();

if (timer.current) return;
if (timer.current) clearTimeout(timer.current);

if (!token || !isLogin) return;

const exp = getExpiration(token);
Expand Down

0 comments on commit 469bcd3

Please sign in to comment.