Skip to content

Commit

Permalink
[chore] useServerLoginCheck 코드 단순화
Browse files Browse the repository at this point in the history
  • Loading branch information
Im-younique committed Jun 8, 2024
1 parent 2ef2507 commit 1dec392
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions client/src/hooks/common/useServerLoginCheck.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@ const useServerLoginCheck = () => {
const cookieStore = cookies();
const token = cookieStore.get('token')?.value;

let initialUserLogin = null;

if (token) {
initialUserLogin = true;
} else {
initialUserLogin = false;
}
const initialUserLogin = !!token;

return initialUserLogin;
};
Expand Down

0 comments on commit 1dec392

Please sign in to comment.