@multiversx/sdk-core
Advanced tools
Comparing version 13.0.0-beta.18 to 13.0.0
@@ -11,3 +11,3 @@ "use strict"; | ||
async runQuery(query) { | ||
const legacyQuery = { | ||
const adaptedQuery = { | ||
address: address_1.Address.fromBech32(query.contract), | ||
@@ -19,10 +19,9 @@ caller: query.caller ? address_1.Address.fromBech32(query.caller) : undefined, | ||
}; | ||
const legacyQueryResponse = await this.networkProvider.queryContract(legacyQuery); | ||
const queryResponse = new smartContractQuery_1.SmartContractQueryResponse({ | ||
const adaptedQueryResponse = await this.networkProvider.queryContract(adaptedQuery); | ||
return new smartContractQuery_1.SmartContractQueryResponse({ | ||
function: query.function, | ||
returnCode: legacyQueryResponse.returnCode.toString(), | ||
returnMessage: legacyQueryResponse.returnMessage, | ||
returnDataParts: legacyQueryResponse.getReturnDataParts(), | ||
returnCode: adaptedQueryResponse.returnCode.toString(), | ||
returnMessage: adaptedQueryResponse.returnMessage, | ||
returnDataParts: adaptedQueryResponse.getReturnDataParts(), | ||
}); | ||
return queryResponse; | ||
} | ||
@@ -29,0 +28,0 @@ } |
@@ -96,3 +96,3 @@ "use strict"; | ||
if (hash.length !== constants_1.HEX_TRANSACTION_HASH_LENGTH) { | ||
throw new errors_1.Err("Invalid transaction hash length. The length of a hex encoded hash should be 64."); | ||
throw new errors_1.Err(`Invalid transaction hash length. The length of a hex encoded hash should be ${constants_1.HEX_TRANSACTION_HASH_LENGTH}.`); | ||
} | ||
@@ -99,0 +99,0 @@ return hash; |
{ | ||
"name": "@multiversx/sdk-core", | ||
"version": "13.0.0-beta.18", | ||
"version": "13.0.0", | ||
"description": "MultiversX SDK for JavaScript and TypeScript", | ||
@@ -5,0 +5,0 @@ "main": "out/index.js", |
Sorry, the diff of this file is not supported yet
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
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1
972846
16170