Fix GetImmediateReply

When scanning an event with positional "e" tags the reply is the last one
This commit is contained in:
Daniele Tonon
2023-05-31 00:10:37 +02:00
committed by fiatjaf_
parent 9cafea7e2a
commit b7ec430166

View File

@ -16,7 +16,7 @@ func GetImmediateReply(tags nostr.Tags) *nostr.Tag {
var root *nostr.Tag
var lastE *nostr.Tag
for i := len(tags) - 1; i >= 0; i-- {
for i := 0; i <= len(tags)-1; i++ {
tag := tags[i]
if len(tag) < 2 {