Fixed decimal strings as value-type properties for JsonRpcSigner (#2948).
This commit is contained in:
parent
66d6aaf4b4
commit
9bf17fa07c
@ -671,7 +671,7 @@ export class JsonRpcProvider extends BaseProvider {
|
|||||||
// JSON-RPC now requires numeric values to be "quantity" values
|
// JSON-RPC now requires numeric values to be "quantity" values
|
||||||
["chainId", "gasLimit", "gasPrice", "type", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "value"].forEach(function(key) {
|
["chainId", "gasLimit", "gasPrice", "type", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "value"].forEach(function(key) {
|
||||||
if ((<any>transaction)[key] == null) { return; }
|
if ((<any>transaction)[key] == null) { return; }
|
||||||
const value = hexValue((<any>transaction)[key]);
|
const value = hexValue(BigNumber.from((<any>transaction)[key]));
|
||||||
if (key === "gasLimit") { key = "gas"; }
|
if (key === "gasLimit") { key = "gas"; }
|
||||||
result[key] = value;
|
result[key] = value;
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user