Skip to content

Commit

Permalink
Merge pull request #88 from innovationacademy-kr/fe/dev/bug_accessToken/
Browse files Browse the repository at this point in the history
#86

[FE] FIX: removeCookie 삭제 도메인 변경 #86
  • Loading branch information
42inshin authored Jan 8, 2024
2 parents 2dd6ab0 + 24d43ef commit dd21e42
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/api/cookie/cookies.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
const tokenName = import.meta.env.VITE_TOKEN;
const domain = new URL(window.location.origin).hostname;

export const getCookie = () => {
return document.cookie
Expand All @@ -11,5 +10,6 @@ export const getCookie = () => {
};

export const removeCookie = (): void => {
const domain = ".24hoursarenotenough.42seoul.kr";
document.cookie = `${tokenName}=; path=/; domain=${domain}; expires=Thu, 01 Jan 1970 00:00:01 GMT;`;
};

0 comments on commit dd21e42

Please sign in to comment.