Skip to content

Commit

Permalink
fix bodyclose
Browse files Browse the repository at this point in the history
  • Loading branch information
asmyasnikov committed Dec 30, 2023
1 parent 0c5072a commit 6319092
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion examples/serverless/healthcheck/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (

environ "github.com/ydb-platform/ydb-go-sdk-auth-environ"

"github.com/ydb-platform/ydb-go-sdk/v3"
ydb "github.com/ydb-platform/ydb-go-sdk/v3"
"github.com/ydb-platform/ydb-go-sdk/v3/sugar"
"github.com/ydb-platform/ydb-go-sdk/v3/table"
"github.com/ydb-platform/ydb-go-sdk/v3/table/types"
Expand Down Expand Up @@ -106,6 +106,9 @@ func (s *service) ping(path string) (code int32, err error) {
if err != nil {
return -1, err
}
defer func() {
_ = response.Body.Close()
}()
return int32(response.StatusCode), nil
}

Expand Down

0 comments on commit 6319092

Please sign in to comment.