@curvefi/api 2.56.0 → 2.56.1

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.
Files changed (2) hide show
  1. package/lib/curve.js +4 -4
  2. package/package.json +1 -1
package/lib/curve.js CHANGED
@@ -391,7 +391,7 @@ var Curve = /** @class */ (function () {
391
391
  return __generator(this, function (_h) {
392
392
  switch (_h.label) {
393
393
  case 0:
394
- if (this.chainId === 1313161554)
394
+ if ([252, 1313161554].includes(this.chainId))
395
395
  return [2 /*return*/];
396
396
  if (!useApi) return [3 /*break*/, 2];
397
397
  _a = this.constants;
@@ -679,7 +679,7 @@ var Curve = /** @class */ (function () {
679
679
  return __generator(this, function (_b) {
680
680
  switch (_b.label) {
681
681
  case 0:
682
- if (this.chainId === 1313161554)
682
+ if ([252, 1313161554].includes(this.chainId))
683
683
  return [2 /*return*/, []];
684
684
  currentPoolIds = Object.keys(this.constants.FACTORY_POOLS_DATA);
685
685
  lastPoolIdx = currentPoolIds.length === 0 ? -1 : Number(currentPoolIds[currentPoolIds.length - 1].split("-")[2]);
@@ -772,7 +772,7 @@ var Curve = /** @class */ (function () {
772
772
  return __generator(this, function (_b) {
773
773
  switch (_b.label) {
774
774
  case 0:
775
- if (this.chainId === 1313161554)
775
+ if ([252, 1313161554].includes(this.chainId))
776
776
  return [2 /*return*/, ''];
777
777
  _a = lowerCasePoolDataAddresses;
778
778
  return [4 /*yield*/, getFactoryPoolData.call(this, 0, poolAddress)];
@@ -1113,7 +1113,7 @@ var Curve = /** @class */ (function () {
1113
1113
  this.setContract(this.constants.ALIASES.crypto_calc, cryptoCalcZapABI);
1114
1114
  this.setContract(this.constants.ALIASES.stable_calc, StableCalcZapABI);
1115
1115
  this.setContract(this.constants.ALIASES.factory, factoryABI);
1116
- if (!(this.chainId !== 1313161554)) return [3 /*break*/, 20];
1116
+ if (!(this.chainId !== 1313161554 && this.chainId !== 252)) return [3 /*break*/, 20];
1117
1117
  factoryContract = this.contracts[this.constants.ALIASES.factory].contract;
1118
1118
  _o = this.constants.ALIASES;
1119
1119
  return [4 /*yield*/, factoryContract.admin(this.constantOptions)];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@curvefi/api",
3
- "version": "2.56.0",
3
+ "version": "2.56.1",
4
4
  "description": "JavaScript library for curve.fi",
5
5
  "main": "lib/index.js",
6
6
  "author": "Macket",