Skip to content

Commit

Permalink
kubeadm: fix gocritic lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
SataQiu committed Jan 8, 2023
1 parent 3aff1f9 commit e0f11d9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ issues:
- ineffassign
# TODO(oscr) Remove these excluded directories and fix findings. Due to large amount of findings in different components
# with different owners it's hard to fix everything in a single pr. This will therefore be done in multiple prs.
- path: (pkg/volume/*|test/*|cmd/kubeadm/*|azure/*|pkg/cmd/wait*|request/bearertoken/*|metrics/*|filters/*)
- path: (pkg/volume/*|test/*|azure/*|pkg/cmd/wait*|request/bearertoken/*|metrics/*|filters/*)
linters:
- gocritic

Expand Down
2 changes: 1 addition & 1 deletion cmd/kubeadm/app/cmd/util/cmdutil.go
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ func InteractivelyConfirmAction(action, question string, r io.Reader) error {
return errors.Wrap(err, "couldn't read from standard input")
}
answer := scanner.Text()
if strings.ToLower(answer) == "y" || strings.ToLower(answer) == "yes" {
if strings.EqualFold(answer, "y") || strings.EqualFold(answer, "yes") {
return nil
}

Expand Down

0 comments on commit e0f11d9

Please sign in to comment.