Skip to content

Commit

Permalink
dirty fix for getting the right number of delegators (#338)
Browse files Browse the repository at this point in the history
  • Loading branch information
stepandel authored Jun 12, 2024
1 parent 2027257 commit 2883b13
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app/api/common/delegates/getDelegates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ async function getDelegate(addressOrENSName: string): Promise<Delegate> {
lastTenProps: delegate?.last_10_props?.toFixed() || "0",
numOfDelegators:
// Use cached amount when recalculation is expensive
cachedNumOfDelegators < 1000n
cachedNumOfDelegators < 1000n && namespace === "optimism"
? BigInt(
(await numOfDelegatesQuery)?.[0]?.num_of_delegators.toString() ||
"0"
Expand Down

0 comments on commit 2883b13

Please sign in to comment.