Fix ndk's error by adding relays section to nip05

This commit is contained in:
artur 2024-03-06 12:54:26 +03:00
parent bf54da8f9d
commit 77cb850bbc

View File

@ -993,6 +993,8 @@ app.get(JSON_PATH, async (req, res) => {
_: bunkerPubkey, _: bunkerPubkey,
}, },
nip46: {}, nip46: {},
// FIXME remove when ndk is fixed
relays: {},
}; };
data.nip46[bunkerPubkey] = [BUNKER_RELAY]; data.nip46[bunkerPubkey] = [BUNKER_RELAY];
@ -1013,6 +1015,7 @@ app.get(JSON_PATH, async (req, res) => {
const { data: pubkey } = nip19.decode(rec.npub); const { data: pubkey } = nip19.decode(rec.npub);
data.names[rec.name] = pubkey; data.names[rec.name] = pubkey;
data.nip46[pubkey] = [BUNKER_RELAY]; data.nip46[pubkey] = [BUNKER_RELAY];
data.relays[pubkey] = [BUNKER_RELAY];
} }
res.status(200).send(data); res.status(200).send(data);