Skip to content

Commit

Permalink
Fix: #38 로그인 상태 제거
Browse files Browse the repository at this point in the history
  • Loading branch information
eve712 committed Jun 24, 2021
1 parent b6c0ccb commit e60a441
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions FE/issue-tracker/src/components/login/LoginMain.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ function LoginMain() {
const [isLoginActive, setIsActiveLogin] = useState(false);
const [isInputtedID, setIsInputtedID] = useState(false);
const [isInputtedPW, setIsInputtedPW] = useState(false);
const [isLogin, setIsLogin] = useRecoilState(isLoginState);
const setLoginInfo = useSetRecoilState(loginInfoState);
const [password, setPassword] = useState('');
const history = useHistory();

Expand All @@ -50,8 +48,8 @@ function LoginMain() {
useEffect(() => {
const { code } = queryString.parse(window.location.search);
if (!code) return;
else if (typeof code === 'string' && !isLogin) {
fetchToken({ setIsLogin, setLoginInfo, code, history });
else if (typeof code === 'string') {
fetchToken({ code, history });
}
}, []);

Expand Down

0 comments on commit e60a441

Please sign in to comment.