Skip to content

Commit

Permalink
fix go lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
roytman committed Jan 16, 2023
1 parent 878a9e2 commit d65ef36
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions pkg/builder/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
package builder

import (
"io/ioutil"
"os"
"path/filepath"

yaml "gopkg.in/yaml.v2"
Expand All @@ -14,7 +14,7 @@ import (
func LoadModel(file string) (*Model, error) {
model := &Model{}
if file != "" {
filecontent, err := ioutil.ReadFile(filepath.Clean(file))
filecontent, err := os.ReadFile(filepath.Clean(file))
if err != nil {
return nil, err
}
Expand Down
3 changes: 1 addition & 2 deletions pkg/builder/crds.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ package builder
import (
"bytes"
"io"
"io/ioutil"
"os"
"path"
"path/filepath"
Expand Down Expand Up @@ -45,7 +44,7 @@ func LoadCRDs(dirpath string) ([]*apiextensions.CustomResourceDefinition, error)

for _, file := range files {
// Read file
filecontent, err := ioutil.ReadFile(filepath.Clean(file))
filecontent, err := os.ReadFile(filepath.Clean(file))
if err != nil {
return nil, err
}
Expand Down

0 comments on commit d65ef36

Please sign in to comment.