Skip to content

Commit

Permalink
feat(act): add defer r.Close()
Browse files Browse the repository at this point in the history
  • Loading branch information
Ferenc Sárai committed Aug 3, 2024
1 parent 60e1c13 commit 4536c06
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/bee/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ func (c *Client) DownloadActFile(ctx context.Context, a swarm.Address, opts *api
if err != nil {
return 0, nil, fmt.Errorf("download file %s: %w", a, err)
}

defer r.Close()
h := fileHasher()
size, err = io.Copy(h, r)
if err != nil {
Expand Down

0 comments on commit 4536c06

Please sign in to comment.