Skip to content

Commit

Permalink
fix: 로그아웃 쿠키 안지워지는 오류 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
peageon committed Dec 8, 2023
1 parent 4a80f2b commit a7a856e
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions back/src/modules/auth/auth.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,12 @@ export class AuthService {
}

clearCookies(res: any): boolean {
for (const cookie in res.cookies) {
res.clearCookie(cookie);
try {
res.clearCookie('access_token');
res.clearCookie('refresh_token');
res.clearCookie('loggedin');
} catch (error) {
return false;
}
return true;
}
Expand Down

0 comments on commit a7a856e

Please sign in to comment.