Skip to content

Commit

Permalink
address feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
thelostone-mc committed May 14, 2024
1 parent 9fc121d commit bf3a4be
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { RoundsFilter } from "./RoundsFilter";
import { getExplorerPageTitle } from "./utils/getExplorerPageTitle";
import { RoundsGrid } from "./RoundsGrid";
import { getEnabledChains } from "../../app/chainConfig";
import { useMemo } from "react";

const ExploreRoundsPage = () => {
const [params] = useSearchParams();
Expand All @@ -18,7 +19,7 @@ const ExploreRoundsPage = () => {
// Pass the filter from the search params and build the graphql query
const rounds = useFilterRounds(filter, getEnabledChains());

const publicRounds = rounds.data?.filter(round => round.roundMetadata.roundType?.toLowerCase() !== "private");
const publicRounds = useMemo(() => rounds.data?.filter(round => round.roundMetadata.roundType?.toLowerCase() !== "private"), [rounds]);
rounds.data = publicRounds;

const sectionTitle = getExplorerPageTitle(filter);
Expand Down

0 comments on commit bf3a4be

Please sign in to comment.