@defillama/sdk 2.3.41 → 2.3.42

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/build/general.js CHANGED
@@ -29,7 +29,7 @@ exports.providers = {
29
29
  bsc: createProvider("bsc", "https://bsc-dataseed.binance.org/,https://bsc-dataseed1.defibit.io/,https://bsc-dataseed1.ninicoin.io/,https://bsc-dataseed2.defibit.io/,https://bsc-dataseed2.ninicoin.io/", 56),
30
30
  polygon: createProvider("polygon", "https://polygon-rpc.com/,https://rpc-mainnet.maticvigil.com/", 137),
31
31
  heco: createProvider("heco", "https://http-mainnet.hecochain.com,https://http-mainnet-node.huobichain.com,https://pub001.hg.network/rpc", 128),
32
- fantom: createProvider("fantom", "https://rpc.ftm.tools/,https://rpcapi.fantom.network", 250),
32
+ fantom: createProvider("fantom", "https://rpc.ankr.com/fantom,https://rpc.ftm.tools/,https://rpcapi.fantom.network", 250),
33
33
  rsk: createProvider("rsk", "https://public-node.rsk.co", 30),
34
34
  tomochain: createProvider("tomochain", "https://rpc.tomochain.com", 88),
35
35
  xdai: createProvider("xdai", "https://rpc.xdaichain.com/,https://xdai.poanetwork.dev,https://dai.poa.network,https://xdai-archive.blockscout.com", 100),
@@ -298,6 +298,9 @@ function getLogs(params) {
298
298
  return __generator(this, function (_b) {
299
299
  switch (_b.label) {
300
300
  case 0:
301
+ if (params.toBlock === undefined || params.fromBlock === undefined) {
302
+ throw new Error("toBlock and fromBlock need to be defined in all calls to getLogs");
303
+ }
301
304
  filter = {
302
305
  address: params.target,
303
306
  topics: (_a = params.topics) !== null && _a !== void 0 ? _a : [ethers_1.utils.id(params.topic)],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@defillama/sdk",
3
- "version": "2.3.41",
3
+ "version": "2.3.42",
4
4
  "description": "SDK for calculating TVL",
5
5
  "main": "build/index.js",
6
6
  "scripts": {