Skip to content

Commit

Permalink
Merge pull request #2139 from objectcomputing/bugfix-2138/stop-showin…
Browse files Browse the repository at this point in the history
…g-terms-on-directory

Stop showing termed users in directory
  • Loading branch information
mkimberlin authored Mar 25, 2024
2 parents 87f82ce + e4d30ff commit 1afa797
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions web-ui/src/pages/PeoplePage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import { AppContext } from "../context/AppContext";
import {
selectMemberProfilesLoading,
selectNormalizedMembers,
selectNormalizedMembersAdmin,
} from "../context/selectors";
import { TextField, Grid } from "@mui/material";
import "./PeoplePage.css";
Expand Down Expand Up @@ -37,18 +36,11 @@ const Root = styled('div')({

const PeoplePage = () => {
const { state } = useContext(AppContext);
const loading= selectMemberProfilesLoading(state)
const { userProfile } = state;
const loading = selectMemberProfilesLoading(state)

const [searchText, setSearchText] = useState("");

const isAdmin =
userProfile && userProfile.role && userProfile.role.includes("ADMIN");

const normalizedMembers = isAdmin
? selectNormalizedMembersAdmin(state, searchText)
: selectNormalizedMembers(state, searchText);

const normalizedMembers = selectNormalizedMembers(state, searchText);

const createMemberCards = normalizedMembers.map((member, index) => {
return (
Expand Down

0 comments on commit 1afa797

Please sign in to comment.