commit d942b823b269546039ce23e2831c6dc19840c2ab
parent 8ea01b43a0afdc29ffff3391f8196794b6fe23a8
Author: William Casarin <jb55@jb55.com>
Date: Fri, 18 Nov 2022 20:02:31 -0800
add nip10 marker to boosts
damus web will use these instead of relying on the content which will be
optional
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/damus/Nostr/NostrEvent.swift b/damus/Nostr/NostrEvent.swift
@@ -519,7 +519,8 @@ func make_metadata_event(keypair: Keypair, metadata: NostrMetadata) -> NostrEven
func make_boost_event(pubkey: String, privkey: String, boosted: NostrEvent) -> NostrEvent {
var tags: [[String]] = boosted.tags.filter { tag in tag.count >= 2 && (tag[0] == "e" || tag[0] == "p") }
- tags.append(["e", boosted.id])
+
+ tags.append(["e", boosted.id, "", "root"])
tags.append(["p", boosted.pubkey])
let ev = NostrEvent(content: event_to_json(ev: boosted), pubkey: pubkey, kind: 6, tags: tags)