generated from VLADIMIR/template
fix
This commit is contained in:
@@ -76,7 +76,7 @@ func (s *sender) Send(ctx context.Context, message Message) error {
|
||||
if err != nil {
|
||||
return fmt.Errorf("email: smtp dial %s: %w", addr, err)
|
||||
}
|
||||
defer rawConn.Close()
|
||||
defer func() { _ = rawConn.Close() }()
|
||||
|
||||
conn := tls.Client(rawConn, s.tlsConfig)
|
||||
if deadline, ok := ctx.Deadline(); ok {
|
||||
|
||||
@@ -261,7 +261,9 @@ func (a *scenarioArchive) Unpack(data []byte) (*Bundle, error) {
|
||||
return nil, fmt.Errorf("не удалось открыть запись %q: %w", name, err)
|
||||
}
|
||||
content, err := readEntry(rc)
|
||||
rc.Close()
|
||||
if closeErr := rc.Close(); err == nil {
|
||||
err = closeErr
|
||||
}
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("запись %q: %w", name, err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user