@appliedblockchain/silentdatarollup-viem 1.0.5 → 1.0.7
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/dist/index.js +0 -9
- package/dist/index.mjs +0 -9
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -32,15 +32,6 @@ var sdTransport = (config) => {
|
|
|
32
32
|
const ethersProvider = new import_silentdatarollup_ethers_provider.SilentDataRollupProvider(providerConfig);
|
|
33
33
|
const transport = (0, import_viem.custom)({
|
|
34
34
|
request: async ({ method, params }) => {
|
|
35
|
-
const txData = params?.[0] ?? {};
|
|
36
|
-
if (method === "eth_sendTransaction" && ethersProvider.signer && !txData.nonce) {
|
|
37
|
-
const signerAddress = await ethersProvider.signer.getAddress();
|
|
38
|
-
const nonce = await ethersProvider.getTransactionCount(
|
|
39
|
-
signerAddress,
|
|
40
|
-
"latest"
|
|
41
|
-
);
|
|
42
|
-
txData.nonce = nonce;
|
|
43
|
-
}
|
|
44
35
|
if (method === "eth_getBlockByNumber" && Array.isArray(params) && params.length > 1) {
|
|
45
36
|
params[1] = false;
|
|
46
37
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -8,15 +8,6 @@ var sdTransport = (config) => {
|
|
|
8
8
|
const ethersProvider = new SilentDataRollupProvider(providerConfig);
|
|
9
9
|
const transport = custom({
|
|
10
10
|
request: async ({ method, params }) => {
|
|
11
|
-
const txData = params?.[0] ?? {};
|
|
12
|
-
if (method === "eth_sendTransaction" && ethersProvider.signer && !txData.nonce) {
|
|
13
|
-
const signerAddress = await ethersProvider.signer.getAddress();
|
|
14
|
-
const nonce = await ethersProvider.getTransactionCount(
|
|
15
|
-
signerAddress,
|
|
16
|
-
"latest"
|
|
17
|
-
);
|
|
18
|
-
txData.nonce = nonce;
|
|
19
|
-
}
|
|
20
11
|
if (method === "eth_getBlockByNumber" && Array.isArray(params) && params.length > 1) {
|
|
21
12
|
params[1] = false;
|
|
22
13
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@appliedblockchain/silentdatarollup-viem",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.7",
|
|
4
4
|
"description": "Viem package for Silent Data [Rollup]",
|
|
5
5
|
"author": "Applied Blockchain",
|
|
6
6
|
"homepage": "https://github.com/appliedblockchain/silent-data-rollup-providers#readme",
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"test": "jest"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@appliedblockchain/silentdatarollup-core": "1.0.
|
|
37
|
-
"@appliedblockchain/silentdatarollup-ethers-provider": "1.0.
|
|
36
|
+
"@appliedblockchain/silentdatarollup-core": "1.0.7",
|
|
37
|
+
"@appliedblockchain/silentdatarollup-ethers-provider": "1.0.7",
|
|
38
38
|
"viem": "2.31.4"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|