This commit is contained in:
Mikola
2023-12-05 14:15:04 +03:00
parent b66537f4a4
commit 9e10088494
32 changed files with 137 additions and 139 deletions

View File

@ -15,7 +15,7 @@ export const ProfileHeader = () => {
const dispatch = useDispatch();
const profileInfo = useSelector(getProfileInfo);
const [user] = useState(
localStorage.getItem("role_status") === "18" ? "partner" : "developer",
localStorage.getItem("role_status") === "18" ? "partner" : "developer"
);
const [isLoggingOut, setIsLoggingOut] = useState(false);
@ -30,8 +30,8 @@ export const ProfileHeader = () => {
apiRequest(`/user/me`).then((profileInfo) => {
dispatch(
setProfileInfo(
profileInfo.userCard ? profileInfo.userCard : profileInfo,
),
profileInfo.userCard ? profileInfo.userCard : profileInfo
)
);
});
}, [dispatch]);