From 913db8f37e15fcc44359f6a22a75ba17556b6a3d Mon Sep 17 00:00:00 2001 From: 0xChupaCabra <56636447+0xChupaCabra@users.noreply.github.com> Date: Sat, 20 Jul 2024 12:51:52 +0200 Subject: [PATCH] vfatio - Bugfix (#11051) * ignore sickles * ignore more smaller positions * remove unused code --- projects/vfat/index.js | 2 -- projects/vfat/utils.js | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/projects/vfat/index.js b/projects/vfat/index.js index e4aa86c89cbd..14f334de4a50 100644 --- a/projects/vfat/index.js +++ b/projects/vfat/index.js @@ -197,13 +197,11 @@ async function tvlBaseOptimism(api) { // TVL calculation for Arbitrum and Linea async function tvlArbitrumLinea(api) { const { factory, gaugeFactory, gaugeFactory2, voter, fromBlock, fromBlockSickle, chainName } = config[api.chain]; - const sickles = await fetchSickles(api, factory, fromBlockSickle); const gauges = await fetchGauges2(api, fromBlock, gaugeFactory, gaugeFactory2, voter, chainName); const stakingTokens = await api.multiCall({ abi: 'address:stake', calls: gauges.lp }); await sumLPBalances(api, gauges.lp, sickles, stakingTokens); - await fetchSickleNftPositions(api, sickles, config[api.chain].NonfungiblePositionManager); await fetchSickleNftPositions(api, sickles, config[api.chain].masterchefV3, true); diff --git a/projects/vfat/utils.js b/projects/vfat/utils.js index 0339c2e58325..8f02f4f39345 100644 --- a/projects/vfat/utils.js +++ b/projects/vfat/utils.js @@ -4,7 +4,7 @@ const { sumTokens2 } = require('../helper/unwrapLPs'); async function sumLPBalances(api, gauges, sickles, lpTokens) { api.log(api.chain, sickles.length, gauges.length,) lpTokens.forEach((lpToken, index) => lpTokens[index] = lpToken.toLowerCase()) - let minLPValue = 4e3 + let minLPValue = 10e3 if (lpTokens.length > 200) minLPValue = 15e3 if (lpTokens.length > 400) minLPValue = 25e3