From 446e4ea59f78ac31b9ac29e1425edfa10fee756a Mon Sep 17 00:00:00 2001 From: Bobo Date: Fri, 21 Jun 2024 04:46:11 +0200 Subject: [PATCH] Tier display fix (#1331) --- src/staking-v3/hooks/useDappStaking.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/staking-v3/hooks/useDappStaking.ts b/src/staking-v3/hooks/useDappStaking.ts index 191a69420..eb2fd97b0 100644 --- a/src/staking-v3/hooks/useDappStaking.ts +++ b/src/staking-v3/hooks/useDappStaking.ts @@ -5,6 +5,7 @@ import { AccountLedger, CombinedDappInfo, Constants, + DAppTier, DAppTierRewards, DappStakeInfo, EraInfo, @@ -141,7 +142,7 @@ export function useDappStaking() { () => store.getters['stakingV3/getTiersConfiguration'] ?? initialTiersConfiguration ); - const leaderboard = computed>( + const leaderboard = computed>( () => store.getters['stakingV3/getLeaderboard'] ); @@ -574,7 +575,7 @@ export function useDappStaking() { const getDappTier = (dappId: number): number | undefined => { const tier = leaderboard.value?.get(dappId); - return tier !== undefined ? tier + 1 : undefined; + return tier !== undefined ? tier.tierId + 1 : undefined; }; const fetchStakerInfoToStore = async (): Promise => {