diff --git a/package-lock.json b/package-lock.json index a9d4e3d4..8973fb29 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@multiversx/sdk-core", - "version": "12.19.0", + "version": "12.19.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@multiversx/sdk-core", - "version": "12.19.0", + "version": "12.19.1", "license": "MIT", "dependencies": { "@multiversx/sdk-transaction-decoder": "1.0.2", diff --git a/package.json b/package.json index 2d087686..1175e6a7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@multiversx/sdk-core", - "version": "12.19.0", + "version": "12.19.1", "description": "MultiversX SDK for JavaScript and TypeScript", "main": "out/index.js", "types": "out/index.d.js", diff --git a/src/relayedTransactionV2Builder.spec.ts b/src/relayedTransactionV2Builder.spec.ts index 04e20666..434892a6 100644 --- a/src/relayedTransactionV2Builder.spec.ts +++ b/src/relayedTransactionV2Builder.spec.ts @@ -67,6 +67,7 @@ describe("test relayed v2 transaction builder", function () { gasLimit: 0, chainID: networkConfig.ChainID, data: new TransactionPayload("getContractConfig"), + version: 2, }); await bob.signer.sign(innerTx); @@ -84,9 +85,10 @@ describe("test relayed v2 transaction builder", function () { await alice.signer.sign(relayedTxV2); assert.equal(relayedTxV2.getNonce().valueOf(), 37); + assert.equal(relayedTxV2.getVersion().valueOf(), 2); assert.equal( relayedTxV2.getData().toString(), - "relayedTxV2@000000000000000000010000000000000000000000000000000000000002ffff@0f@676574436f6e7472616374436f6e666967@b6c5262d9837853e2201de357c1cc4c9803988a42d7049d26b7785dd0ac2bd4c6a8804b6fd9cf845fe2c2a622774b1a2dbd0a417c9a0bc3f0563a85bd15e710a"); + "relayedTxV2@000000000000000000010000000000000000000000000000000000000002ffff@0f@676574436f6e7472616374436f6e666967@fc3ed87a51ee659f937c1a1ed11c1ae677e99629fae9cc289461f033e6514d1a8cfad1144ae9c1b70f28554d196bd6ba1604240c1c1dc19c959e96c1c3b62d0c"); }); }); diff --git a/src/relayedTransactionV2Builder.ts b/src/relayedTransactionV2Builder.ts index 2717e775..bd363885 100644 --- a/src/relayedTransactionV2Builder.ts +++ b/src/relayedTransactionV2Builder.ts @@ -98,6 +98,8 @@ export class RelayedTransactionV2Builder { this.innerTransactionGasLimit.valueOf() + this.netConfig.MinGasLimit + this.netConfig.GasPerDataByte * payload.length(), data: payload, chainID: this.netConfig.ChainID, + version: this.innerTransaction.getVersion(), + options: this.innerTransaction.getOptions() }); if (this.relayerNonce) {