mirror of
https://github.com/wneessen/go-mail.git
synced 2024-12-22 18:50:37 +01:00
Refactor error variable in smtp test
Renamed 'err' to 'berr' to avoid shadowing outer variable. This change ensures clearer error handling and avoids potential issues with variable scope and readability in the smtp_test.go file.
This commit is contained in:
parent
77175a2952
commit
f7bdd8fffc
1 changed files with 2 additions and 2 deletions
|
@ -3665,8 +3665,8 @@ func handleTestServerConnection(connection net.Conn, t *testing.T, props *server
|
|||
}
|
||||
time.Sleep(time.Millisecond)
|
||||
if props.EchoBuffer != nil {
|
||||
if _, err := props.EchoBuffer.Write([]byte(data)); err != nil {
|
||||
t.Errorf("failed write to echo buffer: %s", err)
|
||||
if _, berr := props.EchoBuffer.Write([]byte(data)); berr != nil {
|
||||
t.Errorf("failed write to echo buffer: %s", berr)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue