Skip to content

Commit

Permalink
comment
Browse files Browse the repository at this point in the history
  • Loading branch information
matt5346 committed Apr 21, 2024
1 parent 51e4f2b commit f699ee5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion adapters/overnight/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { CHAINS, PROTOCOLS, SNAPSHOTS_BLOCKS, OVN_CONTRACTS, LP_LYNEX, LP_LYNEX_SYMBOL, USD_PLUS_SYMBOL, USD_PLUS_LINEA, USDT_PLUS_SYMBOL, USDT_PLUS_LINEA } from "./sdk/config";
import { SNAPSHOTS_BLOCKS, OVN_CONTRACTS, LP_LYNEX, LP_LYNEX_SYMBOL, USD_PLUS_SYMBOL, USD_PLUS_LINEA, USDT_PLUS_SYMBOL, USDT_PLUS_LINEA } from "./sdk/config";
import { getLPValueByUserAndPoolFromPositions, getUserTVLByBlock, getRebaseForUsersByPoolAtBlock, getTimestampAtBlock } from "./sdk/subgraphDetails";

(BigInt.prototype as any).toJSON = function () {
Expand Down Expand Up @@ -47,6 +47,8 @@ const getData = async () => {
});
}

// counting rebase by blocks range
// [0, 100, 200] -> gonna be counted like [0, 100] + [100, 200]
for (let [index, block] of SNAPSHOTS_BLOCKS.entries()) {
if (!SNAPSHOTS_BLOCKS[index + 1]) continue;
console.log(`Blocks: ${block} -> ${SNAPSHOTS_BLOCKS[index + 1]}`);
Expand Down

0 comments on commit f699ee5

Please sign in to comment.