From 5fcf239a0681f4c9b08c9b865fb23a7f1522515d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Abadesso?= Date: Wed, 29 Jan 2025 13:17:45 -0300 Subject: [PATCH] refactor: blueprint_id is nullable --- .../hathor-rpc-handler/src/rpcMethods/sendNanoContractTx.ts | 2 +- packages/hathor-rpc-handler/src/types/prompt.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/hathor-rpc-handler/src/rpcMethods/sendNanoContractTx.ts b/packages/hathor-rpc-handler/src/rpcMethods/sendNanoContractTx.ts index be006ea..56dcf01 100644 --- a/packages/hathor-rpc-handler/src/rpcMethods/sendNanoContractTx.ts +++ b/packages/hathor-rpc-handler/src/rpcMethods/sendNanoContractTx.ts @@ -26,7 +26,7 @@ import { NanoContractAction } from '@hathor/wallet-lib/lib/nano_contracts/types' const sendNanoContractSchema = z.object({ method: z.string().min(1), - blueprint_id: z.string(), + blueprint_id: z.string().nullable(), nc_id: z.string().nullable(), actions: z.array(z.custom()), args: z.array(z.unknown()).default([]), diff --git a/packages/hathor-rpc-handler/src/types/prompt.ts b/packages/hathor-rpc-handler/src/types/prompt.ts index 0ca8815..2def379 100644 --- a/packages/hathor-rpc-handler/src/types/prompt.ts +++ b/packages/hathor-rpc-handler/src/types/prompt.ts @@ -144,7 +144,7 @@ export interface AddressRequestClientPrompt extends BaseConfirmationPrompt { } export interface NanoContractParams { - blueprintId: string; + blueprintId: string | null; ncId: string | null; actions: NanoContractAction[], method: string;