From beee0e76e78f3c0548c8b42bc7227fc516356a48 Mon Sep 17 00:00:00 2001 From: "P. Reis" Date: Fri, 19 Jul 2024 19:19:04 -0300 Subject: [PATCH] refactor: allow to return undefined in getZapSplits function --- src/utils/zap_split.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/utils/zap_split.ts b/src/utils/zap_split.ts index 68aabc8a..38eecba4 100644 --- a/src/utils/zap_split.ts +++ b/src/utils/zap_split.ts @@ -6,12 +6,12 @@ type ExtraMessage = string; /** Number from 1 to 100, stringified. */ type splitPercentages = string; -type DittoZapSplits = { +export type DittoZapSplits = { [key: Pubkey]: [splitPercentages, ExtraMessage]; }; /** Gets zap splits from NIP-78 in DittoZapSplits format. */ -export async function getZapSplits(store: NStore, pubkey: string): Promise { +export async function getZapSplits(store: NStore, pubkey: string): Promise { const zapSplits: DittoZapSplits = {}; const [event] = await store.query([{ @@ -20,7 +20,7 @@ export async function getZapSplits(store: NStore, pubkey: string): Promise