mirror of
https://github.com/containrrr/watchtower.git
synced 2025-12-13 21:56:38 +01:00
refactor(update): clean up actions/update
- move common arguments to a shared struct - remove unused fields - fix outdated names - improve logging/error handling
This commit is contained in:
parent
cb8e86d705
commit
a6949dede9
4 changed files with 112 additions and 102 deletions
|
|
@ -396,7 +396,10 @@ func (client dockerClient) PullImage(ctx context.Context, container t.Container)
|
|||
return err
|
||||
}
|
||||
|
||||
defer response.Close()
|
||||
defer func() {
|
||||
_ = response.Close()
|
||||
}()
|
||||
|
||||
// the pull request will be aborted prematurely unless the response is read
|
||||
if _, err = io.ReadAll(response); err != nil {
|
||||
log.Error(err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue