Skip to content

Commit

Permalink
fix(explorer): can't convert too large of stake to number (solana-lab…
Browse files Browse the repository at this point in the history
  • Loading branch information
oJshua authored Mar 23, 2022
1 parent 5541a58 commit 911aa5b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions explorer/src/components/account/StakeAccountSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -296,11 +296,11 @@ function isFullyInactivated(
return false;
}

const delegatedStake = stake.delegation.stake.toNumber();
const inactiveStake = activation.inactive;
const delegatedStake = stake.delegation.stake;
const inactiveStake = new BN(activation.inactive);

return (
!stake.delegation.deactivationEpoch.eq(MAX_EPOCH) &&
delegatedStake === inactiveStake
delegatedStake.eq(inactiveStake)
);
}

0 comments on commit 911aa5b

Please sign in to comment.