This commit is contained in:
Ren Amamiya
2023-10-08 09:31:11 +07:00
parent cb91373d33
commit bce76bd41c
66 changed files with 216 additions and 214 deletions

View File

@@ -102,9 +102,7 @@ export function parser(eventContent: string) {
if (word.startsWith('nostr:naddr1') || word.startsWith('naddr1')) {
const naddr = word.replace('nostr:', '').replace(/[^a-zA-Z0-9 ]/g, '');
const decoded = nip19.decode(naddr).data as AddressPointer;
// TODO
console.log('todo: ', decoded);
return word.replace(word, '');
return word.replace(word, `~pub-${decoded.pubkey}~`);
}
// normal word