From f86032e68213087b8f087245851b915b5f6acfa6 Mon Sep 17 00:00:00 2001 From: Runxi Yu Date: Sun, 8 Dec 2024 21:34:30 +0800 Subject: Server & Client should only have pointer receivers --- clients.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'clients.go') diff --git a/clients.go b/clients.go index 16dea78..1c3f8e0 100644 --- a/clients.go +++ b/clients.go @@ -17,7 +17,7 @@ type Client struct { Host string Caps map[string]struct{} Extra map[string]any - Server Server + Server *Server State ClientState } @@ -40,12 +40,12 @@ func (client *Client) SendRaw(s string) error { return nil } -func (client Client) ClientSource() string { +func (client *Client) ClientSource() string { // TODO: Edge cases where these aren't available return client.Nick + "!" + client.Ident + "@" + client.Host } -func (client Client) ServerSource() string { +func (client *Client) ServerSource() string { return client.CID } -- cgit v1.2.3