Skip to content

Commit

Permalink
fix: do not fetch Prime distributions if user is not Prime (#1707)
Browse files Browse the repository at this point in the history
  • Loading branch information
therealemjy authored Nov 3, 2023
1 parent e67baf3 commit 87c74da
Show file tree
Hide file tree
Showing 4 changed files with 687 additions and 11 deletions.
5 changes: 5 additions & 0 deletions src/__mocks__/contracts/prime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ const primeResponses: {
getAllMarkets: Awaited<ReturnType<Prime['getAllMarkets']>>;
calculateAPR: Awaited<ReturnType<Prime['calculateAPR']>>;
estimateAPR: Awaited<ReturnType<Prime['estimateAPR']>>;
tokens: Awaited<ReturnType<Prime['tokens']>>;
} = {
MINIMUM_STAKED_XVS: BN.from('1000000000000000000000'),
getAllMarkets: [
Expand All @@ -22,6 +23,10 @@ const primeResponses: {
borrowAPR: BN.from('20'),
supplyAPR: BN.from('23'),
} as Awaited<ReturnType<Prime['estimateAPR']>>,
tokens: {
exists: true,
isIrrevocable: false,
} as Awaited<ReturnType<Prime['tokens']>>,
};

export default primeResponses;
Loading

0 comments on commit 87c74da

Please sign in to comment.