@ethersproject/transactions
Advanced tools
Comparing version 5.0.0-beta.129 to 5.0.0-beta.130
@@ -1,1 +0,1 @@ | ||
export declare const version = "transactions/5.0.0-beta.129"; | ||
export declare const version = "transactions/5.0.0-beta.130"; |
@@ -1,1 +0,1 @@ | ||
export const version = "transactions/5.0.0-beta.129"; | ||
export const version = "transactions/5.0.0-beta.130"; |
@@ -27,7 +27,7 @@ "use strict"; | ||
const transactionFields = [ | ||
{ name: "nonce", maxLength: 32 }, | ||
{ name: "gasPrice", maxLength: 32 }, | ||
{ name: "gasLimit", maxLength: 32 }, | ||
{ name: "nonce", maxLength: 32, numeric: true }, | ||
{ name: "gasPrice", maxLength: 32, numeric: true }, | ||
{ name: "gasLimit", maxLength: 32, numeric: true }, | ||
{ name: "to", length: 20 }, | ||
{ name: "value", maxLength: 32 }, | ||
{ name: "value", maxLength: 32, numeric: true }, | ||
{ name: "data" }, | ||
@@ -50,3 +50,7 @@ ]; | ||
let value = transaction[fieldInfo.name] || ([]); | ||
value = arrayify(hexlify(value)); | ||
const options = {}; | ||
if (fieldInfo.numeric) { | ||
options.hexPad = "left"; | ||
} | ||
value = arrayify(hexlify(value, options)); | ||
// Fixed-width field | ||
@@ -53,0 +57,0 @@ if (fieldInfo.length && value.length !== fieldInfo.length && value.length > 0) { |
@@ -1,1 +0,1 @@ | ||
export declare const version = "transactions/5.0.0-beta.129"; | ||
export declare const version = "transactions/5.0.0-beta.130"; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.version = "transactions/5.0.0-beta.129"; | ||
exports.version = "transactions/5.0.0-beta.130"; |
@@ -35,7 +35,7 @@ "use strict"; | ||
var transactionFields = [ | ||
{ name: "nonce", maxLength: 32 }, | ||
{ name: "gasPrice", maxLength: 32 }, | ||
{ name: "gasLimit", maxLength: 32 }, | ||
{ name: "nonce", maxLength: 32, numeric: true }, | ||
{ name: "gasPrice", maxLength: 32, numeric: true }, | ||
{ name: "gasLimit", maxLength: 32, numeric: true }, | ||
{ name: "to", length: 20 }, | ||
{ name: "value", maxLength: 32 }, | ||
{ name: "value", maxLength: 32, numeric: true }, | ||
{ name: "data" }, | ||
@@ -60,3 +60,7 @@ ]; | ||
var value = transaction[fieldInfo.name] || ([]); | ||
value = bytes_1.arrayify(bytes_1.hexlify(value)); | ||
var options = {}; | ||
if (fieldInfo.numeric) { | ||
options.hexPad = "left"; | ||
} | ||
value = bytes_1.arrayify(bytes_1.hexlify(value, options)); | ||
// Fixed-width field | ||
@@ -63,0 +67,0 @@ if (fieldInfo.length && value.length !== fieldInfo.length && value.length > 0) { |
{ | ||
"name": "@ethersproject/transactions", | ||
"version": "5.0.0-beta.129", | ||
"version": "5.0.0-beta.130", | ||
"description": "Utilities for decoding and encoding Ethereum transaction for ethers.", | ||
@@ -36,3 +36,3 @@ "main": "./lib/index.js", | ||
"ethereum": "donations.ethers.eth", | ||
"tarballHash": "0x3f7a71b90c61d3a7c2c3d4203f3dd13a3f0cfd0dfad36d1c1fe58258bb929617" | ||
"tarballHash": "0xf36ee5a842381d97052254b0ad453155ae0007253a4605a3e1a0a8e63a47b549" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
99034
374