mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-08-09 16:14:40 +00:00
A "like" on a group message was built as a plain NIP-25 reaction — `e` (message) + `p` (author) + `k` — with no `h` tag. The recipient's only notification query that reaches the group's host relay, filterGroupNotificationsToPubkey, is scoped `#p`=them AND `#h`=their groups (kind 7 is already in GroupNotificationKinds), so a like with no `h` tag is never matched there. It would only surface if NIP-65 routing happened to drop it on one of the recipient's inbox relays — never for a host-relay-only group — so likes on group messages effectively never notified. Copy the target's `h` tag onto public reactions to group-scoped events, mirroring how kind-9 replies carry it. ReactionEvent.build gains an `initializer` (the API GroupScope's KDoc already documented); ReactionAction applies the group `h` tag for both the tracked and fire-and-forget paths. The like now lands on the host relay in-group and the existing kind-7 `#p`+`#h` query picks it up. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VxpT7J4xt37EF5yJDw1htK