Add update functions to lists, document Encryptable, fix tag inheritance

This commit is contained in:
Jon Staab
2024-10-07 14:03:12 -07:00
parent 944ee61b88
commit 2156aeaeb5
3 changed files with 67 additions and 7 deletions
+2 -2
View File
@@ -40,14 +40,14 @@ export const tagReplyTo = (event: TrustedEvent) => {
}
// Inherit p-tag mentions
for (const pubkey of getPubkeyTagValues(tags)) {
for (const pubkey of getPubkeyTagValues(event.tags)) {
if (pubkey !== $pubkey) {
tags.push(tagPubkey(pubkey))
}
}
// Based on NIP 10 legacy tags, order is root, mentions, reply
const {roots, replies, mentions} = getAncestorTags(tags)
const {roots, replies, mentions} = getAncestorTags(event.tags)
// Root comes first
if (roots.length > 0) {