Skip to content
This repository has been archived by the owner on Jan 24, 2024. It is now read-only.

Commit

Permalink
fix(rari-fuse): Remove market in label, add Aave V2 as a dependency (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
immasandwich authored Jul 20, 2022
1 parent efa1003 commit e881657
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ import { Inject } from '@nestjs/common';

import { APP_TOOLKIT, IAppToolkit } from '~app-toolkit/app-toolkit.interface';
import { Register } from '~app-toolkit/decorators';
import { getLabelFromToken } from '~app-toolkit/helpers/presentation/image.present';
import { AAVE_V2_DEFINITION } from '~apps/aave-v2';
import { ARRAKIS_DEFINITION } from '~apps/arrakis/arrakis.definition';
import { CompoundContractFactory } from '~apps/compound';
import { CompoundSupplyTokenHelper } from '~apps/compound/helper/compound.supply.token-helper';
Expand Down Expand Up @@ -37,6 +39,7 @@ export class EthereumRariFuseSupplyTokenFetcher implements PositionFetcher<AppTo
const baseTokens = await this.appToolkit.getBaseTokenPrices(network);
const appTokens = await this.appToolkit.getAppTokenPositions(
{ appId: CURVE_DEFINITION.id, groupIds: [CURVE_DEFINITION.groups.pool.id], network },
{ appId: AAVE_V2_DEFINITION.id, groupIds: [AAVE_V2_DEFINITION.groups.supply.id], network },
{
appId: YEARN_DEFINITION.id,
groupIds: [YEARN_DEFINITION.groups.v1Vault.id, YEARN_DEFINITION.groups.v2Vault.id],
Expand Down Expand Up @@ -72,7 +75,7 @@ export class EthereumRariFuseSupplyTokenFetcher implements PositionFetcher<AppTo
getUnderlyingAddress: ({ contract, multicall }) => multicall.wrap(contract).underlying(),
getExchangeRateMantissa: ({ underlyingTokenDecimals, tokenDecimals }) =>
18 + underlyingTokenDecimals - tokenDecimals,
getDisplayLabel: async ({ underlyingToken }) => `${underlyingToken.symbol} in ${pool.name}`,
getDisplayLabel: async ({ underlyingToken }) => getLabelFromToken(underlyingToken),
});
}),
);
Expand Down

0 comments on commit e881657

Please sign in to comment.