mirror of
https://github.com/hzrd149/nostrudel.git
synced 2025-08-08 09:12:26 +02:00
fix share post being set as reaction
This commit is contained in:
@@ -6,7 +6,7 @@ import accountService from "../services/account";
|
|||||||
import { Kind } from "nostr-tools";
|
import { Kind } from "nostr-tools";
|
||||||
|
|
||||||
export function isReply(event: NostrEvent | DraftNostrEvent) {
|
export function isReply(event: NostrEvent | DraftNostrEvent) {
|
||||||
return !!event.tags.find((tag) => isETag(tag) && tag[3] !== "mention");
|
return event.tags.filter(isETag).some((tag) => tag[3] !== "mention");
|
||||||
}
|
}
|
||||||
|
|
||||||
export function isNote(event: NostrEvent | DraftNostrEvent) {
|
export function isNote(event: NostrEvent | DraftNostrEvent) {
|
||||||
@@ -96,7 +96,7 @@ export function buildShare(event: NostrEvent): DraftNostrEvent {
|
|||||||
tags.push(["p", event.pubkey]);
|
tags.push(["p", event.pubkey]);
|
||||||
|
|
||||||
return {
|
return {
|
||||||
kind: Kind.Reaction,
|
kind: Kind.Text,
|
||||||
// TODO: be smarter about picking relay
|
// TODO: be smarter about picking relay
|
||||||
tags,
|
tags,
|
||||||
content: "#[0]",
|
content: "#[0]",
|
||||||
|
Reference in New Issue
Block a user