refactor: replace ioutil=>io; update linter (#1211)

This commit is contained in:
Christopher Angelo Phillips
2022-09-16 17:58:16 +00:00
committed by GitHub
parent 0a1cd25ba5
commit b48316742f
11 changed files with 14 additions and 22 deletions
+2 -2
View File
@@ -3,7 +3,7 @@ package packages
import (
"context"
"fmt"
"io/ioutil"
"io"
"os"
"github.com/wagoodman/go-partybus"
@@ -162,7 +162,7 @@ func runPackageSbomUpload(src *source.Source, s sbom.SBOM, app *config.Applicati
return fmt.Errorf("unable to open dockerfile=%q: %w", app.Anchore.Dockerfile, err)
}
dockerfileContents, err = ioutil.ReadAll(fh)
dockerfileContents, err = io.ReadAll(fh)
if err != nil {
return fmt.Errorf("unable to read dockerfile=%q: %w", app.Anchore.Dockerfile, err)
}