Skip to content

Commit 3fddb17

Browse files
committed
Fix tx search query
1 parent eb65ce0 commit 3fddb17

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@initia/initia.js",
3-
"version": "0.1.23",
3+
"version": "0.1.24",
44
"description": "The JavaScript SDK for Initia",
55
"license": "MIT",
66
"author": "InitiaLabs",

src/client/lcd/api/TxAPI.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ export namespace SimulateResponse {
188188
}
189189

190190
export interface TxSearchOptions extends PaginationOptions {
191-
events: { key: string; value: string }[];
191+
query: { key: string; value: string }[];
192192
}
193193

194194
export class TxAPI extends BaseAPI {
@@ -542,14 +542,14 @@ export class TxAPI extends BaseAPI {
542542
const params = new URLSearchParams();
543543

544544
// build search params
545-
options.events?.forEach(v =>
545+
options.query?.forEach(v =>
546546
params.append(
547-
'events',
547+
'query',
548548
v.key === 'tx.height' ? `${v.key}=${v.value}` : `${v.key}='${v.value}'`
549549
)
550550
);
551551

552-
delete options['events'];
552+
delete options['query'];
553553

554554
Object.entries(options).forEach(v => {
555555
params.append(v[0], v[1] as string);

0 commit comments

Comments
 (0)