Skip to content

Commit f123955

Browse files
committed
fix: pass client by reference
:|
1 parent 73df523 commit f123955

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

manager/manager.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import (
1313
)
1414

1515
// NewServer creates a new server manager
16-
func NewServer(guildID string, clients Clients) *Server {
16+
func NewServer(guildID string, clients *Clients) *Server {
1717
return &Server{
1818
Queue: queue.NewQueue(),
1919
Custom: make(map[string]*database.CustomCommand),

manager/structure.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ type Server struct {
5555
// Whether the DJ mode is enabled
5656
DjMode bool
5757
// Clients used for interacting with the various APIs
58-
Clients Clients
58+
Clients *Clients
5959
}
6060

6161
// YtDLP structure for holding yt-dlp data

utilities.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@ import (
66

77
func initializeServer(guild string) {
88
if _, ok := server[guild]; !ok {
9-
server[guild] = manager.NewServer(guild, clients)
9+
server[guild] = manager.NewServer(guild, &clients)
1010
}
1111
}

0 commit comments

Comments
 (0)