From fcce8eb980abe8dfe69ac4840ae4b51a1f361784 Mon Sep 17 00:00:00 2001 From: Asara Date: Mon, 23 Sep 2024 21:35:31 -0400 Subject: [PATCH] allow all to send zap receipts --- nostr/policies.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nostr/policies.go b/nostr/policies.go index 35fe774..2c4785e 100644 --- a/nostr/policies.go +++ b/nostr/policies.go @@ -16,11 +16,12 @@ func RejectUnregisteredNpubs(ctx context.Context, event *nostr.Event) (reject bo // always allow the following kinds // 13: nip-59 seals + // 9735: nip-57 zap receipt // 21000: lightning.pub rpc // 22242: nip-42 client auth // 30078: nip-78 addressable events switch event.Kind { - case 13, 21000, 22242, 30078: + case 13, 9735, 21000, 22242, 30078: return false, "" } @@ -38,10 +39,9 @@ func RejectUnregisteredNpubs(ctx context.Context, event *nostr.Event) (reject bo // 4: nip-04 encrypted dms // 14: nip-17 private dms // 1059: nip-59 gift wraps - // 9735: nip-57 zap receipt // 24133: nip-46 nostr connect switch event.Kind { - case 4, 14, 1059, 9735, 24133: + case 4, 14, 1059, 24133: for _, npub := range event.Tags.GetAll([]string{"p"}) { npubs = append(npubs, npub.Value()) }