mirror of
https://github.com/QuantumNous/new-api.git
synced 2026-09-11 14:41:21 +00:00
refactor: remove mutex from CustomEvent and update TCP connection handling in tests
This commit is contained in:
@@ -364,7 +364,7 @@ func TestSMTPPlainAuthRejectsRemotePlaintextConnection(t *testing.T) {
|
||||
SMTPFrom = "sender@example.com"
|
||||
SMTPToken = "secret"
|
||||
|
||||
conn, err := net.Dial("tcp", fmt.Sprintf("%s:%d", server.host, server.port))
|
||||
conn, err := net.Dial("tcp", net.JoinHostPort(server.host, strconv.Itoa(server.port)))
|
||||
require.NoError(t, err)
|
||||
client, err := smtp.NewClient(conn, SMTPServer)
|
||||
require.NoError(t, err)
|
||||
|
||||
Reference in New Issue
Block a user