Skip to content

Commit

Permalink
Merge pull request #158 from Step3-kakao-tech-campus/feat/#138
Browse files Browse the repository at this point in the history
fix: 쿠키 이름 변경(userAccountInfo -> accountInfo)
  • Loading branch information
LimSumi authored Nov 5, 2023
2 parents 92318d2 + 3db1250 commit 1a641e7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/commons/UserDropdownBox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ const UserDropdownBox = () => {
const options = ['My 정보 변경', 'My 보호소 이동', '로그아웃'];
const [isDropdownOpen, setIsDropdownOpen] = useState(false); // 드롭다운 메뉴 열림/닫힘 상태
const navigate = useNavigate();
const shelterId = getCookie('userAccountInfo');
const id = shelterId ? shelterId.split(' ')[1] : '';
const shelterId = getCookie('accountInfo');
const id = shelterId ? shelterId.id : '';

const toggleDropdown = () => {
setIsDropdownOpen(!isDropdownOpen);
Expand Down
2 changes: 2 additions & 0 deletions src/pages/shelterInfo/VShelterInfo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ export interface Props {
const VShelterInfo = (props: Props) => {
const loginAccount = getCookie('accountInfo');
console.log(loginAccount);
console.log(loginAccount.role);
console.log(loginAccount.id);

return (
<div>
Expand Down

0 comments on commit 1a641e7

Please sign in to comment.