nip5 handles

This commit is contained in:
2023-08-23 14:14:38 +01:00
parent c191a7684a
commit 7cba67e4c1
3 changed files with 38 additions and 8 deletions

View File

@ -37,8 +37,9 @@ export function useZaps(goal: NostrEvent, leaveOpen = false) {
);
}
export function useZapGoal(host: string, link: NostrLink, leaveOpen = false) {
export function useZapGoal(host: string, link?: NostrLink, leaveOpen = false) {
const sub = useMemo(() => {
if (!link) return null;
const b = new RequestBuilder(`goals:${host.slice(0, 12)}`);
b.withOptions({ leaveOpen });
b.withFilter()