sdk/js-query: fix solana mock for dataSliceOffset == 0

This commit is contained in:
Evan Gray 2024-01-23 16:13:36 -05:00 committed by Evan Gray
parent da9d97f933
commit 79c1927a78
4 changed files with 8 additions and 4 deletions

View File

@ -1,3 +1,7 @@
## 0.0.8
Fix SolanaAccount mock for minContextSlot and dataSliceOffset == 0
## 0.0.7
Add EthCallByTimestamp mock support

View File

@ -1,12 +1,12 @@
{
"name": "@wormhole-foundation/wormhole-query-sdk",
"version": "0.0.7",
"version": "0.0.8",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "@wormhole-foundation/wormhole-query-sdk",
"version": "0.0.7",
"version": "0.0.8",
"license": "Apache-2.0",
"dependencies": {
"@ethersproject/keccak256": "^5.7.0",

View File

@ -1,6 +1,6 @@
{
"name": "@wormhole-foundation/wormhole-query-sdk",
"version": "0.0.7",
"version": "0.0.8",
"description": "Wormhole cross-chain query SDK",
"homepage": "https://wormhole.com",
"main": "./lib/cjs/index.js",

View File

@ -416,7 +416,7 @@ export class QueryProxyMock {
if (query.minContextSlot != BigInt(0)) {
opts.minSlotContext = Number(query.minContextSlot);
}
if (query.dataSliceOffset !== BigInt(0)) {
if (query.dataSliceLength !== BigInt(0)) {
opts.dataSlice = {
offset: Number(query.dataSliceOffset),
length: Number(query.dataSliceLength),