forked from DefiLlama/DefiLlama-Adapters
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add btcfi projects and token mappings for BFC (DefiLlama#9377)
* add btcfi projects * Add token mappings for BFC --------- Co-authored-by: tlatkdgus1 <[email protected]>
- Loading branch information
1 parent
513de8a
commit ba8c323
Showing
3 changed files
with
26 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
const ADDRESSES = require('../helper/coreAssets.json') | ||
const { sumTokens2, } = require('../helper/unwrapLPs') | ||
|
||
const chainPools = { | ||
bfc: { | ||
WBTC: { pool: '0xEa3b4a2dA5DbE8379AD4c60aaD5184df69D7C9AD', token: ADDRESSES.bfc.WBTC }, | ||
BTCB: { pool: '0x0B31FeE8bF53bFe2f5F7083B73A4c9C8B517E32F', token: ADDRESSES.bfc.BTCB } | ||
}, | ||
} | ||
|
||
Object.keys(chainPools).forEach(chain => { | ||
const pools = chainPools[chain] | ||
module.exports[chain] = { | ||
tvl: async (_, _b, _cb, { api, }) => { | ||
return sumTokens2({ api, tokensAndOwners: Object.values(pools).map(({ pool, token }) => ([token, pool,])) }) | ||
} | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters