add missing float capital markets

This commit is contained in:
0xngmi
2021-11-08 07:41:10 +00:00
parent 09a0ce7ed2
commit 5b12279551
2 changed files with 5 additions and 7 deletions

View File

@@ -1,17 +1,15 @@
const { sumTokens} = require('../helper/unwrapLPs')
const vault = "0xce5da4bebBA980BeC39da5b118750A47a23D4B85"
const vaults = ["0xce5da4bebBA980BeC39da5b118750A47a23D4B85", "0x595b1408C9c2BF121c7674E270Ca7aCc0bBf100C", "0x694c240e63CF60a2cD2d38d84D902744640AcCDA"]
const amDAI = "0x27f8d03b3a2196956ed754badc28d73be8830a6e"
async function tvl(time, ethBlock, chainBlocks){
const balances = {}
await sumTokens(balances, [[
"0x27f8d03b3a2196956ed754badc28d73be8830a6e", // amDAI
vault
]], chainBlocks.polygon, "polygon", addr=>`polygon:${addr}`)
await sumTokens(balances, vaults.map(v=>[amDAI, v]), chainBlocks.polygon, "polygon", addr=>`polygon:${addr}`)
return balances
}
module.exports={
tvl,
methodology: `Gets the tokens on ${vault}`
methodology: `Gets the tokens on markets`
}

View File

@@ -78,5 +78,5 @@ const ethTvl = async (timestamp, ethBlock, chainBlocks) => {
};
module.exports = {
tvl: sdk.util.sumChainTvls([ethTvl]),
tvl: ethTvl
};