on master help sign in
points: don't show transfers or rejected points in main list
commit158748f085f05892d561fbace33080b0c32c71de authorHunter Miller <hunter@thisdot.co> dateMon 7 Feb 2022, 16:37 (5 years ago) parent479ce22
1 file changed+8−1
src/views/Points.tsx+8−1
src/views/Points.tsx+8−1
@@ -121,7 +121,14 @@ export default function Points() {
121121 [getDetails, controlledPoints, _contracts]
122122 );
123123
124− const allPoints = pointList.filter(({ shouldDisplay }) => shouldDisplay);
124+ const allPoints = useMemo(
125+ () =>
126+ pointList.filter(
127+ ({ isTransferProxy, shouldDisplay, value }) =>
128+ shouldDisplay && !isTransferProxy && !rejectedPoints.includes(value)
129+ ),
130+ [pointList, rejectedPoints]
131+ );
125132
126133 // if we can only interact with a single point, jump to the point page.
127134 // if there are any pending transfers, incoming or outgoing, stay on this