fix: admin user role_id

This commit is contained in:
shuai 2023-03-07 16:29:13 +08:00
parent a6720613bd
commit 105811d47e
1 changed files with 1 additions and 1 deletions

View File

@ -56,7 +56,7 @@ const Index = () => {
const { setUsers } = usePageUsers();
const userInfo = loggedUserInfoStore((state) => state.user);
const isAuthor = userInfo?.username === question?.user_info?.username;
const isAdmin = userInfo?.is_admin;
const isAdmin = userInfo?.role_id === 2;
const isLogged = Boolean(userInfo?.access_token);
const { state: locationState } = useLocation();