nostrdb: nip19: add kind to naddr & nevent

Add support for type KIND for bech32-encoded entities naddr and nevent
as specified in NIP-19.

Co-authored-by: kernelkind <kernelkind@gmail.com>
Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin
2025-02-13 15:13:07 -08:00
committed by Daniel D’Aquino
parent a51618cfd3
commit d8e7b4707e
2 changed files with 22 additions and 15 deletions

View File

@@ -368,11 +368,15 @@ struct bech32_nevent {
struct ndb_relays relays;
const unsigned char *event_id;
const unsigned char *pubkey; // optional
uint32_t kind;
bool has_kind;
};
struct bech32_nprofile {
struct ndb_relays relays;
const unsigned char *pubkey;
uint32_t kind;
bool has_kind;
};
struct bech32_naddr {