Skip to content

Commit 146c331

Browse files
authored
Merge pull request #244 from curvefi/fix/fixed-fetchNewStableNgFactoryPools
fix: fixed fetchNewStableNgFactoryPools
2 parents 78c8d23 + 4b75d33 commit 146c331

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@curvefi/api",
3-
"version": "2.53.2",
3+
"version": "2.53.3",
44
"description": "JavaScript library for curve.fi",
55
"main": "lib/index.js",
66
"author": "Macket",

src/curve.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -817,9 +817,9 @@ class Curve implements ICurve {
817817

818818
fetchNewStableNgFactoryPools = async (): Promise<string[]> => {
819819
const currentPoolIds = Object.keys(this.constants.STABLE_NG_FACTORY_POOLS_DATA);
820-
const lastPoolIdx = currentPoolIds.length === 0 ? -1 : Number(currentPoolIds[currentPoolIds.length - 1].split("-")[2]);
821-
const poolData = lowerCasePoolDataAddresses(await getFactoryPoolData.call(this, lastPoolIdx + 1));
822-
this.constants.STABLE_NG_FACTORY_POOLS_DATA = { ...this.constants.FACTORY_POOLS_DATA, ...poolData };
820+
const lastPoolIdx = currentPoolIds.length === 0 ? -1 : Number(currentPoolIds[currentPoolIds.length - 1].split("-")[3]);
821+
const poolData = lowerCasePoolDataAddresses(await getFactoryPoolData.call(this, lastPoolIdx + 1, undefined, this.constants.ALIASES.stable_ng_factory));
822+
this.constants.STABLE_NG_FACTORY_POOLS_DATA = { ...this.constants.STABLE_NG_FACTORY_POOLS_DATA, ...poolData };
823823
this._updateDecimalsAndGauges(this.constants.STABLE_NG_FACTORY_POOLS_DATA);
824824

825825
return Object.keys(poolData)

0 commit comments

Comments
 (0)