mirror of
https://github.com/aljazceru/njump.git
synced 2025-12-17 06:14:22 +01:00
get rid of false positives for isntRealRelay() by not eliminating the path from the relay URL.
This commit is contained in:
5
nostr.go
5
nostr.go
@@ -3,7 +3,6 @@ package main
|
|||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"net/url"
|
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/fiatjaf/eventstore"
|
"github.com/fiatjaf/eventstore"
|
||||||
@@ -163,9 +162,7 @@ func getEvent(ctx context.Context, code string, relayHints []string) (*nostr.Eve
|
|||||||
}()
|
}()
|
||||||
|
|
||||||
for ie := range pool.SubManyEoseNonUnique(ctx, relays, nostr.Filters{filter}) {
|
for ie := range pool.SubManyEoseNonUnique(ctx, relays, nostr.Filters{filter}) {
|
||||||
if pu, err := url.Parse(ie.Relay.URL); err == nil {
|
successRelays = append(successRelays, ie.Relay.URL)
|
||||||
successRelays = append(successRelays, pu.Scheme+"://"+pu.Host+pu.RawPath)
|
|
||||||
}
|
|
||||||
result = ie.Event
|
result = ie.Event
|
||||||
countdown = min(countdown, 1)
|
countdown = min(countdown, 1)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user