Skip to content

Commit

Permalink
admin users can now edit user accounts
Browse files Browse the repository at this point in the history
  • Loading branch information
Jaek23 committed May 1, 2024
1 parent d2909ee commit 7fe8e24
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion client/src/components/UserManagement/ManageUsers.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import UpdateUser from "./UpdateUser";
import DeactivateUser from "./DeactivateUser";
import ActivateUser from "./ActivateUser";
import axios from "axios";
import { isAdminUser } from "../../utils/AdminReportingRoles";

const ManageUsers = ({ userObj, toggleShow, doShow, getAllUsers }) => {
const [resetting, setResetting] = useState(-1);
Expand Down Expand Up @@ -111,7 +112,7 @@ const ManageUsers = ({ userObj, toggleShow, doShow, getAllUsers }) => {
></span>
</h4>
<div className={doShow ? "formFields" : "hideIt"}>
{userObj.isAdmin ? (
{isAdminUser(userObj) ? (
<Tab.Container defaultActiveKey="active-users">
<Nav variant="tabs">
<Nav.Item>
Expand Down

0 comments on commit 7fe8e24

Please sign in to comment.