Skip to content

Commit

Permalink
fix: render per epoch rewards instead of total rewards
Browse files Browse the repository at this point in the history
  • Loading branch information
neuodev committed Jun 6, 2023
1 parent 8995f96 commit d66d175
Showing 1 changed file with 2 additions and 2 deletions.
Expand Up @@ -48,7 +48,7 @@ type Intl = {|

function RewardHistoryDialog({ graphData, onClose, intl }: Props & Intl): Node {
const rewardItems = graphData.rewardsGraphData.items;
const rewardList = rewardItems?.totalRewards.filter(p => Boolean(p.primary)) ?? [];
const rewardList = rewardItems?.perEpochRewards.filter(p => Boolean(p.primary)) ?? [];
const rewardsByPoolName = useMemo(() => groupByPoolName(rewardList), []);

return (
Expand Down Expand Up @@ -82,7 +82,7 @@ function RewardHistoryDialog({ graphData, onClose, intl }: Props & Intl): Node {
key={poolName}
// $FlowFixMe[incompatible-use]: Object entries flow type
poolId={data.poolId}
poolName={poolName}
poolName={poolName || '-'}
// $FlowFixMe[incompatible-use]: Object entries flow type
poolAvatar={data.poolAvatar}
// $FlowFixMe[incompatible-use]: Object entries flow type
Expand Down

0 comments on commit d66d175

Please sign in to comment.