Skip to main content

validateGas

Callable

  • validateGas(transaction: { accessList?: { readonly address?: string | undefined; readonly storageKeys?: string[] | undefined; }[]; chain?: ValidChains; chainId?: string; common?: { customChain: { name?: string | undefined; networkId: string; chainId: string; }; baseChain?: ValidChains | undefined; hardfork?: Hardfork | undefined; }; data?: string; from?: string; gas?: string; gasLimit?: string; gasPrice?: string; hardfork?: Hardfork; input?: string; maxFeePerGas?: string; maxPriorityFeePerGas?: string; networkId?: string; nonce?: string; r?: string; s?: string; to?: null | string; type?: string; v?: string; value?: string; yParity?: string }): void

  • This method checks if all required gas properties are present for either legacy gas (type 0x0 and 0x1) OR fee market transactions (0x2)


    Parameters

    • transaction: { accessList?: { readonly address?: string | undefined; readonly storageKeys?: string[] | undefined; }[]; chain?: ValidChains; chainId?: string; common?: { customChain: { name?: string | undefined; networkId: string; chainId: string; }; baseChain?: ValidChains | undefined; hardfork?: Hardfork | undefined; }; data?: string; from?: string; gas?: string; gasLimit?: string; gasPrice?: string; hardfork?: Hardfork; input?: string; maxFeePerGas?: string; maxPriorityFeePerGas?: string; networkId?: string; nonce?: string; r?: string; s?: string; to?: null | string; type?: string; v?: string; value?: string; yParity?: string }

    Returns void