Skip to content

Commit

Permalink
Merge pull request #95 from edenia/feat/voters
Browse files Browse the repository at this point in the history
fix(pages): don't show inactive members
  • Loading branch information
xavier506 authored Oct 13, 2022
2 parents e44b2ea + b9865cb commit 3c4897d
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/components/Voters/Body/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,15 @@ const Body: React.FC<BodyVoters> = ({ searchValue }) => {
setLoadingData(true)
const members = await smartProxyUtil.getEdenMembers(
nextKey === '' ? undefined : nextKey,
20
40
)

if (members) {
const activeMembers = members?.rows?.filter(
member => member[1]?.status === 1
)
const electionRankSize = await genesisEdenUtil.getRanks()
const membersCompleteDataPromise = members?.rows?.map(async member => {
const membersCompleteDataPromise = activeMembers.map(async member => {
const { rows } = await smartProxyUtil.getVotes(
member[1]?.account,
member[1]?.account,
Expand Down

0 comments on commit 3c4897d

Please sign in to comment.