diff options
Diffstat (limited to 'relay.go')
| -rw-r--r-- | relay.go | 4 |
1 files changed, 2 insertions, 2 deletions
| @@ -6,7 +6,7 @@ import ( | |||
| 6 | "fmt" | 6 | "fmt" |
| 7 | "sync" | 7 | "sync" |
| 8 | 8 | ||
| 9 | "github.com/coder/websocket" | 9 | "northwest.io/nostr/internal/websocket" |
| 10 | ) | 10 | ) |
| 11 | 11 | ||
| 12 | // Relay represents a connection to a Nostr relay. | 12 | // Relay represents a connection to a Nostr relay. |
| @@ -24,7 +24,7 @@ type Relay struct { | |||
| 24 | 24 | ||
| 25 | // Connect establishes a WebSocket connection to the relay. | 25 | // Connect establishes a WebSocket connection to the relay. |
| 26 | func Connect(ctx context.Context, url string) (*Relay, error) { | 26 | func Connect(ctx context.Context, url string) (*Relay, error) { |
| 27 | conn, _, err := websocket.Dial(ctx, url, nil) | 27 | conn, err := websocket.Dial(ctx, url) |
| 28 | if err != nil { | 28 | if err != nil { |
| 29 | return nil, fmt.Errorf("failed to connect to relay: %w", err) | 29 | return nil, fmt.Errorf("failed to connect to relay: %w", err) |
| 30 | } | 30 | } |
