Merge pull request #133 from nikolat/master

add root marker by default in channels
This commit is contained in:
hzrd149 2024-05-18 06:51:06 -05:00 committed by GitHub
commit bb7915a2e0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -39,7 +39,7 @@ export default function ChannelMessageForm({
let draft: DraftNostrEvent = {
kind: kinds.ChannelMessage,
content: values.content,
tags: [["e", channel.id]],
tags: [["e", rootId || channel.id, "", "root"]],
created_at: dayjs().unix(),
};
@ -47,10 +47,6 @@ export default function ChannelMessageForm({
draft = createEmojiTags(draft, emojis);
draft = ensureNotifyPubkeys(draft, contentMentions);
if (rootId) {
draft.tags.push(["e", rootId, "", "root"]);
}
setLoadingMessage("Signing...");
await publish("Send DM", draft, undefined, false);
reset();