@curvefi/api 2.41.1 → 2.41.3
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/lib/boosting.js +1 -1
- package/lib/curve.d.ts +1 -0
- package/lib/curve.js +9 -3
- package/lib/index.d.ts +1 -0
- package/package.json +1 -1
package/lib/boosting.js
CHANGED
|
@@ -516,7 +516,7 @@ var _sendBlockhash = function (block, chainId, estimateGas) { return __awaiter(v
|
|
|
516
516
|
case 2:
|
|
517
517
|
_a.sent();
|
|
518
518
|
gasLimit = mulBy1_3(gas);
|
|
519
|
-
return [4 /*yield*/, veOracleContract.
|
|
519
|
+
return [4 /*yield*/, veOracleContract.send_blockhash(block, chainId, __assign(__assign({}, curve.options), { gasLimit: gasLimit }))];
|
|
520
520
|
case 3: return [2 /*return*/, (_a.sent()).hash];
|
|
521
521
|
}
|
|
522
522
|
});
|
package/lib/curve.d.ts
CHANGED
package/lib/curve.js
CHANGED
|
@@ -655,7 +655,7 @@ var Curve = /** @class */ (function () {
|
|
|
655
655
|
var _a;
|
|
656
656
|
if (options === void 0) { options = {}; }
|
|
657
657
|
return __awaiter(this, void 0, void 0, function () {
|
|
658
|
-
var _b, e_1, _c, network, poolId, _d, cTokens, yTokens, ycTokens, aTokens, customAbiTokens, _e, err_1, _i, _f, pool, _g, _h, coinAddr, _j, _k, coinAddr, _l, _m, coinAddr, _minterABI, addressProviderContract, _o, factoryContract, _p;
|
|
658
|
+
var jsonRpcApiProviderOptions, _b, e_1, _c, network, poolId, _d, cTokens, yTokens, ycTokens, aTokens, customAbiTokens, _e, err_1, _i, _f, pool, _g, _h, coinAddr, _j, _k, coinAddr, _l, _m, coinAddr, _minterABI, addressProviderContract, _o, factoryContract, _p;
|
|
659
659
|
return __generator(this, function (_q) {
|
|
660
660
|
switch (_q.label) {
|
|
661
661
|
case 0:
|
|
@@ -690,11 +690,17 @@ var Curve = /** @class */ (function () {
|
|
|
690
690
|
};
|
|
691
691
|
if (!(providerType.toLowerCase() === 'JsonRpc'.toLowerCase())) return [3 /*break*/, 6];
|
|
692
692
|
providerSettings = providerSettings;
|
|
693
|
+
jsonRpcApiProviderOptions = void 0;
|
|
694
|
+
if (providerSettings.batchMaxCount) {
|
|
695
|
+
jsonRpcApiProviderOptions = {
|
|
696
|
+
batchMaxCount: providerSettings.batchMaxCount,
|
|
697
|
+
};
|
|
698
|
+
}
|
|
693
699
|
if (providerSettings.url) {
|
|
694
|
-
this.provider = new ethers.JsonRpcProvider(providerSettings.url);
|
|
700
|
+
this.provider = new ethers.JsonRpcProvider(providerSettings.url, undefined, jsonRpcApiProviderOptions);
|
|
695
701
|
}
|
|
696
702
|
else {
|
|
697
|
-
this.provider = new ethers.JsonRpcProvider('http://localhost:8545/');
|
|
703
|
+
this.provider = new ethers.JsonRpcProvider('http://localhost:8545/', undefined, jsonRpcApiProviderOptions);
|
|
698
704
|
}
|
|
699
705
|
if (!providerSettings.privateKey) return [3 /*break*/, 1];
|
|
700
706
|
this.signer = new ethers.Wallet(providerSettings.privateKey, this.provider);
|
package/lib/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import { PoolTemplate } from "./pools/index.js";
|
|
|
3
3
|
declare function init(providerType: 'JsonRpc' | 'Web3' | 'Infura' | 'Alchemy', providerSettings: {
|
|
4
4
|
url?: string;
|
|
5
5
|
privateKey?: string;
|
|
6
|
+
batchMaxCount?: number;
|
|
6
7
|
} | {
|
|
7
8
|
externalProvider: ethers.Eip1193Provider;
|
|
8
9
|
} | {
|