Fix gas price estimation for V5 oracle: now, if bumpPercent not specified, using bumpPercent depending on tx type and chain ID & bump package version to 1.4.0

This commit is contained in:
Theo 2023-08-28 03:44:25 -07:00
parent 57c24e21eb
commit 342c34b07a
2 changed files with 2 additions and 2 deletions

@ -1,6 +1,6 @@
{
"name": "@tornado/tornado-oracles",
"version": "1.3.2",
"version": "1.4.0",
"description": "Gas oracle for Tornado-specific transactions",
"main": "./lib/index.js",
"types": "./lib/index.d.ts",

@ -125,7 +125,7 @@ export abstract class TornadoFeeOracle implements ITornadoFeeOracle {
async getGasPrice(
type: TxType = 'other',
speed: LegacyGasPriceKey = 'fast',
bumpPercent: number = 0,
bumpPercent?: number,
): Promise<HexadecimalStringifiedNumber> {
const gasPriceParams = await this.getGasPriceParams(type, speed, bumpPercent);
return calculateGasPriceInWei(gasPriceParams).toHexString();