@curvefi/api 2.50.3 → 2.50.5
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.
|
@@ -1858,9 +1858,9 @@ var PoolTemplate = /** @class */ (function () {
|
|
|
1858
1858
|
};
|
|
1859
1859
|
PoolTemplate.prototype.claimRewards = function () {
|
|
1860
1860
|
return __awaiter(this, void 0, void 0, function () {
|
|
1861
|
-
var gaugeContract, gasLimit, _c;
|
|
1862
|
-
return __generator(this, function (
|
|
1863
|
-
switch (
|
|
1861
|
+
var gaugeContract, gasLimit, _c, _d;
|
|
1862
|
+
return __generator(this, function (_e) {
|
|
1863
|
+
switch (_e.label) {
|
|
1864
1864
|
case 0:
|
|
1865
1865
|
if (this.gauge === curve.constants.ZERO_ADDRESS) {
|
|
1866
1866
|
throw Error("claimRewards method doesn't exist for pool ".concat(this.name, " (id: ").concat(this.name, "). There is no gauge"));
|
|
@@ -1869,11 +1869,12 @@ var PoolTemplate = /** @class */ (function () {
|
|
|
1869
1869
|
if (!("claim_rewards()" in gaugeContract))
|
|
1870
1870
|
throw Error("".concat(this.name, " pool doesn't have such method"));
|
|
1871
1871
|
_c = mulBy1_3;
|
|
1872
|
+
_d = DIGas;
|
|
1872
1873
|
return [4 /*yield*/, gaugeContract.claim_rewards.estimateGas(curve.constantOptions)];
|
|
1873
1874
|
case 1:
|
|
1874
|
-
gasLimit = _c.apply(void 0, [_d.sent()]);
|
|
1875
|
+
gasLimit = _c.apply(void 0, [_d.apply(void 0, [_e.sent()])]);
|
|
1875
1876
|
return [4 /*yield*/, gaugeContract.claim_rewards(__assign(__assign({}, curve.options), { gasLimit: gasLimit }))];
|
|
1876
|
-
case 2: return [2 /*return*/, (
|
|
1877
|
+
case 2: return [2 /*return*/, (_e.sent()).hash];
|
|
1877
1878
|
}
|
|
1878
1879
|
});
|
|
1879
1880
|
});
|
|
@@ -407,7 +407,7 @@ export var depositPlainMixin = {
|
|
|
407
407
|
if (estimateGas)
|
|
408
408
|
return [2 /*return*/, smartNumber(gas)];
|
|
409
409
|
gasLimit = mulBy1_3(DIGas(gas));
|
|
410
|
-
return [4 /*yield*/, contract.add_liquidity(_amounts, _minMintAmount, __assign(__assign({}, curve.options), { gasLimit: gasLimit, value: value }))];
|
|
410
|
+
return [4 /*yield*/, contract.add_liquidity(_amounts, _minMintAmount, false, __assign(__assign({}, curve.options), { gasLimit: gasLimit, value: value }))];
|
|
411
411
|
case 5: return [2 /*return*/, (_a.sent()).hash];
|
|
412
412
|
}
|
|
413
413
|
});
|
|
@@ -380,7 +380,7 @@ export var withdrawOneCoinPlainMixin = {
|
|
|
380
380
|
if (estimateGas)
|
|
381
381
|
return [2 /*return*/, smartNumber(gas)];
|
|
382
382
|
gasLimit = mulBy1_3(DIGas(gas));
|
|
383
|
-
return [4 /*yield*/, contract.remove_liquidity_one_coin(_lpTokenAmount, i, _minAmount, __assign(__assign({}, curve.options), { gasLimit: gasLimit }))];
|
|
383
|
+
return [4 /*yield*/, contract.remove_liquidity_one_coin(_lpTokenAmount, i, _minAmount, false, __assign(__assign({}, curve.options), { gasLimit: gasLimit }))];
|
|
384
384
|
case 3: return [2 /*return*/, (_a.sent()).hash];
|
|
385
385
|
}
|
|
386
386
|
});
|