update go-nostr so just "localhost[:port]" works as a relay url.

This commit is contained in:
fiatjaf
2024-07-05 00:11:59 -03:00
parent 9a41450209
commit 441ee9a5ed
3 changed files with 3 additions and 8 deletions

View File

@@ -4,7 +4,6 @@ import (
"context"
"encoding/json"
"fmt"
"strings"
"github.com/nbd-wtf/go-nostr/nip11"
"github.com/urfave/cli/v3"
@@ -22,10 +21,6 @@ var relay = &cli.Command{
return fmt.Errorf("specify the <relay-url>")
}
if !strings.HasPrefix(url, "wss://") && !strings.HasPrefix(url, "ws://") {
url = "wss://" + url
}
info, err := nip11.Fetch(ctx, url)
if err != nil {
lineProcessingError(ctx, "failed to fetch '%s' information document: %w", url, err)