Skip to content

Commit

Permalink
fix:💥breaking change on the API - update symbol (DefiLlama#11746)
Browse files Browse the repository at this point in the history
  • Loading branch information
rcheiko authored and Adolf998 committed Sep 29, 2024
1 parent e346d8e commit 27f4635
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions projects/liqwid/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,9 @@ const query = `query($input: MarketsInput) {
page
pagesCount
results {
id
asset {
id
symbol
qTokenName
qTokenCurrencySymbol
currencySymbol
name
decimals
Expand All @@ -61,13 +59,13 @@ const query = `query($input: MarketsInput) {
`

const tokenMapping = {
ADA: 'lovelace',
Ada: 'lovelace',
DJED: '8db269c3ec630e06ae29f74bc39edd1f87c819f1056206e879a1cd61446a65644d6963726f555344',
DAI: 'dai',

}

const getToken = (market) => tokenMapping[market.asset.symbol] ?? market.asset.currencySymbol + toHex(market.asset.name)
const getToken = (market) => tokenMapping[market.id] ?? market.asset.currencySymbol + toHex(market.asset.name)

const getOptimBondTVL = async () => {
const getLoans = async (pageIndex = 0, collectedLoans = []) => {
Expand Down

0 comments on commit 27f4635

Please sign in to comment.