@curvefi/api 1.5.0 → 1.5.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/pools.js +4 -1
  2. package/package.json +1 -1
package/lib/pools.js CHANGED
@@ -558,7 +558,7 @@ var Pool = /** @class */ (function () {
558
558
  if (!['aave', 'saave', 'ib'].includes(this.name)) return [3 /*break*/, 3];
559
559
  return [4 /*yield*/, this._removeLiquidity(_lpTokenAmount, false, true)];
560
560
  case 2: return [2 /*return*/, _a.sent()];
561
- case 3: return [4 /*yield*/, this._removeLiquiditySwap(_lpTokenAmount)];
561
+ case 3: return [4 /*yield*/, this._removeLiquiditySwap(_lpTokenAmount, true)];
562
562
  case 4: return [2 /*return*/, _a.sent()];
563
563
  }
564
564
  });
@@ -903,6 +903,9 @@ var Pool = /** @class */ (function () {
903
903
  return __generator(this, function (_a) {
904
904
  switch (_a.label) {
905
905
  case 0:
906
+ if (['compound', 'usdt', 'y', 'busd', 'pax'].includes(this.name)) {
907
+ throw Error(this.name + " pool doesn't have remove_liquidity_one_coin method for wrapped tokens");
908
+ }
906
909
  i = this._getCoinIdx(coin, false);
907
910
  _lpTokenAmount = ethers_1.ethers.utils.parseUnits(lpTokenAmount);
908
911
  if (!(this.name === 'ib')) return [3 /*break*/, 2];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@curvefi/api",
3
- "version": "1.5.0",
3
+ "version": "1.5.1",
4
4
  "description": "JavaScript library for curve.fi",
5
5
  "main": "lib/index.js",
6
6
  "scripts": {